summaryrefslogtreecommitdiff
path: root/graphics/libungif
diff options
context:
space:
mode:
authorwiz <wiz@pkgsrc.org>2006-02-01 07:10:03 +0000
committerwiz <wiz@pkgsrc.org>2006-02-01 07:10:03 +0000
commit93725233a77b970a91d84bd3cdceb3d510f0d480 (patch)
tree76255530d96b8e7160c005f0ec1a31fc6b880163 /graphics/libungif
parentf878fb5eb89ae3c905fa243866e2dec4aade3f55 (diff)
downloadpkgsrc-93725233a77b970a91d84bd3cdceb3d510f0d480.tar.gz
Update to 4.1.4, provided by Matthew Luckie in PR 32688:
Version 4.1.4 ============= This version fixes some bugs with deallocating ColorMaps and fix building on several platforms. * Fix several areas in decoding where we removed a ColorMap from our GifFile but didn't set the pointer to NULL. This could lead to double free's of the ColorMap. * Fix a bug in dev2gif.c where we redefined some gl types incorrectly. * Fix building on Windows. Note -- there has been one API changing event for Windows (renaming DrawText to DrawGifText.) This should have conflicted with Windows API and therefore caused the builds to fail previously. If you had it working with DrawText before, apologies, you'll need to change to DrawGifText in your code. This only affects Windows. * Add support for building on The Game Boy Advance. Note: Due to the GBA's limited memory, the API for the GBA uses short's in many places where the other platforms use ints. This shouldn't affect anyone unless you've been able to get an older version of the code to run on GBA and want to start using this version instead. A recompile of your dependent code will be necessary in this case.
Diffstat (limited to 'graphics/libungif')
-rw-r--r--graphics/libungif/Makefile11
-rw-r--r--graphics/libungif/distinfo12
-rw-r--r--graphics/libungif/patches/patch-aa25
-rw-r--r--graphics/libungif/patches/patch-ac16
-rw-r--r--graphics/libungif/patches/patch-ad63
-rw-r--r--graphics/libungif/patches/patch-ae21
6 files changed, 8 insertions, 140 deletions
diff --git a/graphics/libungif/Makefile b/graphics/libungif/Makefile
index 431be3013f2..aa78c5d91f4 100644
--- a/graphics/libungif/Makefile
+++ b/graphics/libungif/Makefile
@@ -1,7 +1,6 @@
-# $NetBSD: Makefile,v 1.36 2005/12/05 20:50:21 rillig Exp $
+# $NetBSD: Makefile,v 1.37 2006/02/01 07:10:03 wiz Exp $
-DISTNAME= libungif-4.1.3
-PKGREVISION= 3
+DISTNAME= libungif-4.1.4
CATEGORIES= graphics
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=libungif/}
EXTRACT_SUFX= .tar.bz2
@@ -14,17 +13,15 @@ CONFLICTS= giflib-[0-9]*
PKG_INSTALLATION_TYPES= overwrite pkgviews
-USE_LIBTOOL= yes
-LTCONFIG_OVERRIDE= ${WRKSRC}/ltconfig
-
GNU_CONFIGURE= yes
+USE_LIBTOOL= yes
CONFIGURE_ARGS+= --without-x
CONFIGURE_ENV+= ac_cv_lib_X11_main=no
DOCDIR= ${PREFIX}/share/doc/libungif
HTMLDIR= ${PREFIX}/share/doc/html/libungif
-REPLACE_PERL= util/gifburst
+REPLACE_PERL+= util/gifburst
post-patch:
@${RM} ${WRKSRC}/doc/gif2x11.html
diff --git a/graphics/libungif/distinfo b/graphics/libungif/distinfo
index 7607ae94140..8b8d6901e59 100644
--- a/graphics/libungif/distinfo
+++ b/graphics/libungif/distinfo
@@ -1,10 +1,6 @@
-$NetBSD: distinfo,v 1.10 2005/11/05 13:32:36 adrianp Exp $
+$NetBSD: distinfo,v 1.11 2006/02/01 07:10:03 wiz Exp $
-SHA1 (libungif-4.1.3.tar.bz2) = 04aab31b3e9e719a80320667bc23b3ee35505a34
-RMD160 (libungif-4.1.3.tar.bz2) = 287abf7560f5394e62c475f0d722938842ba6786
-Size (libungif-4.1.3.tar.bz2) = 439960 bytes
-SHA1 (patch-aa) = eb2d1f1d21e19adc8bc33dcbd24be5c20560f4fd
+SHA1 (libungif-4.1.4.tar.bz2) = af687ffbcfe6afd1d76e33ea8cf27ffb02ed61fc
+RMD160 (libungif-4.1.4.tar.bz2) = f96782d4e305e393a22acd84317c13dc265a21f3
+Size (libungif-4.1.4.tar.bz2) = 482222 bytes
SHA1 (patch-ab) = a93e2fe0a93aacda4566e723e681fd316fe2cb2a
-SHA1 (patch-ac) = 58985225879ea2d60a1eb9e8a17595f8a0ed95a5
-SHA1 (patch-ad) = dc5e0123b950674abe46be6508f3f8bb1a69641d
-SHA1 (patch-ae) = 43b271ae9ec6eddd8341526e6b8636c503cd209c
diff --git a/graphics/libungif/patches/patch-aa b/graphics/libungif/patches/patch-aa
deleted file mode 100644
index 2032bb7b68c..00000000000
--- a/graphics/libungif/patches/patch-aa
+++ /dev/null
@@ -1,25 +0,0 @@
-$NetBSD: patch-aa,v 1.7 2005/03/20 11:07:33 schwarz Exp $
-
---- util/gif2iris.c.orig 2005-03-19 17:50:38.000000000 +0100
-+++ util/gif2iris.c 2005-03-19 18:06:18.000000000 +0100
-@@ -30,6 +30,9 @@
- #include "gl.h"
- #include "device.h"
-
-+#ifndef __MSDOS__
-+#include <stdlib.h>
-+#endif
- #include <stdio.h>
- #include <ctype.h>
- #include <string.h>
-@@ -229,8 +232,8 @@
- BackGround = GifFile->SBackGroundColor;
- ColorMap = (GifFile->Image.ColorMap ? GifFile->Image.ColorMap :
- GifFile->SColorMap);
-- ColorMapSize = 1 << (GifFile->Image.ColorMap ? GifFile->Image.BitsPerPixel :
-- GifFile->SBitsPerPixel);
-+ ColorMapSize = 1 << (GifFile->Image.ColorMap ? GifFile->Image.ColorMap->BitsPerPixel :
-+ GifFile->SColorMap->BitsPerPixel);
- GifQprintf("\n");
- Screen2Iris(ScreenBuffer, GifFile->SWidth, GifFile->SHeight);
-
diff --git a/graphics/libungif/patches/patch-ac b/graphics/libungif/patches/patch-ac
deleted file mode 100644
index 2e3cbca05b1..00000000000
--- a/graphics/libungif/patches/patch-ac
+++ /dev/null
@@ -1,16 +0,0 @@
-$NetBSD: patch-ac,v 1.6 2005/11/05 13:32:36 adrianp Exp $
-
---- lib/gifalloc.c.orig 2004-05-29 19:59:59.000000000 +0100
-+++ lib/gifalloc.c
-@@ -420,8 +420,10 @@ FreeSavedImages(GifFileType * GifFile) {
- }
- for (sp = GifFile->SavedImages;
- sp < GifFile->SavedImages + GifFile->ImageCount; sp++) {
-- if (sp->ImageDesc.ColorMap)
-+ if (sp->ImageDesc.ColorMap) {
- FreeMapObject(sp->ImageDesc.ColorMap);
-+ sp->ImageDesc.ColorMap = NULL;
-+ }
-
- if (sp->RasterBits)
- free((char *)sp->RasterBits);
diff --git a/graphics/libungif/patches/patch-ad b/graphics/libungif/patches/patch-ad
deleted file mode 100644
index b865bbea60d..00000000000
--- a/graphics/libungif/patches/patch-ad
+++ /dev/null
@@ -1,63 +0,0 @@
-$NetBSD: patch-ad,v 1.1 2005/11/05 13:32:36 adrianp Exp $
-
---- lib/dgif_lib.c.orig 2004-05-29 19:59:59.000000000 +0100
-+++ lib/dgif_lib.c
-@@ -263,6 +263,7 @@ DGifGetScreenDesc(GifFileType * GifFile)
- for (i = 0; i < GifFile->SColorMap->ColorCount; i++) {
- if (READ(GifFile, Buf, 3) != 3) {
- FreeMapObject(GifFile->SColorMap);
-+ GifFile->SColorMap = NULL;
- _GifError = D_GIF_ERR_READ_FAILED;
- return GIF_ERROR;
- }
-@@ -363,6 +364,7 @@ DGifGetImageDesc(GifFileType * GifFile)
- for (i = 0; i < GifFile->Image.ColorMap->ColorCount; i++) {
- if (READ(GifFile, Buf, 3) != 3) {
- FreeMapObject(GifFile->Image.ColorMap);
-+ GifFile->Image.ColorMap = NULL;
- _GifError = D_GIF_ERR_READ_FAILED;
- return GIF_ERROR;
- }
-@@ -923,6 +925,12 @@ DGifDecompressInput(GifFileType * GifFil
- 0x0fff
- };
-
-+ /* The image can't contain more than LZ_BITS per code. */
-+ if (Private->RunningBits > LZ_BITS) {
-+ _GifError = D_GIF_ERR_IMAGE_DEFECT;
-+ return GIF_ERROR;
-+ }
-+
- while (Private->CrntShiftState < Private->RunningBits) {
- /* Needs to get more bytes from input stream for next code: */
- if (DGifBufferedInput(GifFile, Private->Buf, &NextByte) == GIF_ERROR) {
-@@ -938,8 +946,12 @@ DGifDecompressInput(GifFileType * GifFil
- Private->CrntShiftState -= Private->RunningBits;
-
- /* If code cannot fit into RunningBits bits, must raise its size. Note
-- * however that codes above 4095 are used for special signaling. */
-- if (++Private->RunningCode > Private->MaxCode1 &&
-+ * however that codes above 4095 are used for special signaling.
-+ * If we're using LZ_BITS bits already and we're at the max code, just
-+ * keep using the table as it is, don't increment Private->RunningCode.
-+ */
-+ if (Private->RunningCode < LZ_MAX_CODE + 2 &&
-+ ++Private->RunningCode > Private->MaxCode1 &&
- Private->RunningBits < LZ_BITS) {
- Private->MaxCode1 <<= 1;
- Private->RunningBits++;
-@@ -964,6 +976,14 @@ DGifBufferedInput(GifFileType * GifFile,
- _GifError = D_GIF_ERR_READ_FAILED;
- return GIF_ERROR;
- }
-+ /* There shouldn't be any empty data blocks here as the LZW spec
-+ * says the LZW termination code should come first. Therefore we
-+ * shouldn't be inside this routine at that point.
-+ */
-+ if (Buf[0] == 0) {
-+ _GifError = D_GIF_ERR_IMAGE_DEFECT;
-+ return GIF_ERROR;
-+ }
- if (READ(GifFile, &Buf[1], Buf[0]) != Buf[0]) {
- _GifError = D_GIF_ERR_READ_FAILED;
- return GIF_ERROR;
diff --git a/graphics/libungif/patches/patch-ae b/graphics/libungif/patches/patch-ae
deleted file mode 100644
index dc7de70a1f1..00000000000
--- a/graphics/libungif/patches/patch-ae
+++ /dev/null
@@ -1,21 +0,0 @@
-$NetBSD: patch-ae,v 1.1 2005/11/05 13:32:36 adrianp Exp $
-
---- lib/egif_lib.c.orig 2004-05-29 22:53:36.000000000 +0100
-+++ lib/egif_lib.c
-@@ -712,10 +712,14 @@ EGifCloseFile(GifFileType * GifFile) {
- Buf = ';';
- WRITE(GifFile, &Buf, 1);
-
-- if (GifFile->Image.ColorMap)
-+ if (GifFile->Image.ColorMap) {
- FreeMapObject(GifFile->Image.ColorMap);
-- if (GifFile->SColorMap)
-+ GifFile->Image.ColorMap = NULL;
-+ }
-+ if (GifFile->SColorMap) {
- FreeMapObject(GifFile->SColorMap);
-+ GifFile->SColorMap = NULL;
-+ }
- if (Private) {
- free((char *)Private);
- }