Commit bcb1f993 authored by Graham Inggs's avatar Graham Inggs

Build with giflib5

parent 62bb1cce
......@@ -9,6 +9,7 @@ qutemol (0.4.1~cvs20081111-4) UNRELEASED; urgency=low
[ Graham Inggs ]
* Acknowledge NMU from Olly Betts. (Closes: #760619)
* Build with giflib5, thanks Matthias Klose. (Closes: #803290)
-- Michael Banck <mbanck@debian.org> Sun, 06 Oct 2013 18:50:04 +0200
......
......@@ -4,7 +4,7 @@ Priority: optional
Maintainer: Debichem Team <debichem-devel@lists.alioth.debian.org>
Uploaders: Morten Kjeldgaard <mok0@ubuntu.com>, Michael Banck <mbanck@debian.org>
Build-Depends: debhelper (>= 9), cdbs, libwxgtk3.0-dev, libglew1.5-dev,
libgif-dev, libpng12-dev
libgif-dev (>= 5), libpng12-dev
Standards-Version: 3.9.3.1
Homepage: http://qutemol.sourceforge.net/
Vcs-Browser: http://svn.debian.org/wsvn/debichem/
......
From: Matthias Klose <doko@debian.org>
Subject: modification to source code
--- a/src/gifSave.cpp
+++ b/src/gifSave.cpp
@@ -63,10 +63,10 @@
b[i]=data[j++];
}
- outputPalette = MakeMapObject(paletteSize, NULL);
+ outputPalette = GifMakeMapObject(paletteSize, NULL);
if (!outputPalette) return false;
- if (QuantizeBuffer(sx, sy, &paletteSize,
+ if (GifQuantizeBuffer(sx, sy, &paletteSize,
&(r[0]),&(g[0]),&(b[0]), &(output[0]),
outputPalette->Colors) == GIF_ERROR) return false;
@@ -114,7 +114,10 @@
unsigned char nsle[12] = "NETSCAPE2.0";
unsigned char subblock[3];
//if (EGifPutExtension(gf, 0xFF, 11, nsle) == GIF_ERROR) {
- if (EGifPutExtensionFirst(gf, APPLICATION_EXT_FUNC_CODE, 11, nsle) == GIF_ERROR) {
+ if (EGifPutExtensionLeader(gf, APPLICATION_EXT_FUNC_CODE) == GIF_ERROR) {
+ return false;
+ }
+ if (EGifPutExtensionBlock(gf, 11, nsle) == GIF_ERROR) {
//gif_push_error();
//i_push_error(0, "writing loop extension");
return false;
@@ -123,7 +126,7 @@
subblock[2] = loop_count % 256;
subblock[1] = loop_count / 256;
//if (EGifPutExtension(gf, 0, 3, subblock) == GIF_ERROR) {
- if (EGifPutExtensionLast(gf, APPLICATION_EXT_FUNC_CODE, 3, subblock) == GIF_ERROR) {
+ if (EGifPutExtensionTrailer(gf) == GIF_ERROR) {
//gif_push_error();
//i_push_error(0, "writing loop extention sub-block");
return false;
@@ -144,7 +147,7 @@
if (frames.size()==0) return false;
- GifFileType *GifFile = EGifOpenFileName(filename, FALSE);
+ GifFileType *GifFile = EGifOpenFileName(filename, 0, NULL);
if (!GifFile) return false;
@@ -172,7 +175,7 @@
if (EGifPutImageDesc(
GifFile,
- 0, 0, gifsx, gifsy, FALSE, NULL
+ 0, 0, gifsx, gifsy, 0, NULL
) == GIF_ERROR) return false;
@@ -181,7 +184,7 @@
}
}
- if (EGifCloseFile(GifFile) == GIF_ERROR) return false;
+ if (EGifCloseFile(GifFile, NULL) == GIF_ERROR) return false;
mode_t mask = umask(0);
umask(mask);
......@@ -34,3 +34,4 @@
34_geometry_tab_sliders.patch
35_gifsave_honor_umask.patch
36_wx3.0_compat.patch
37_giflib5.patch
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment