packages: gif2png/gif2png-libpng.patch (NEW) - fixes build with libpng 1.4 ...
megabajt
megabajt at pld-linux.org
Mon Feb 8 17:01:10 CET 2010
Author: megabajt Date: Mon Feb 8 16:01:11 2010 GMT
Module: packages Tag: HEAD
---- Log message:
- fixes build with libpng 1.4 (from Gentoo)
---- Files affected:
packages/gif2png:
gif2png-libpng.patch (NONE -> 1.1) (NEW)
---- Diffs:
================================================================
Index: packages/gif2png/gif2png-libpng.patch
diff -u /dev/null packages/gif2png/gif2png-libpng.patch:1.1
--- /dev/null Mon Feb 8 17:01:11 2010
+++ packages/gif2png/gif2png-libpng.patch Mon Feb 8 17:01:03 2010
@@ -0,0 +1,30 @@
+--- a/gif2png.c.orig 2006-07-07 16:40:33.000000000 -0400
++++ b/gif2png.c 2006-07-07 16:43:25.000000000 -0400
+@@ -135,7 +135,7 @@
+ unsigned long hist_maxvalue;
+ int passcount;
+ int errtype, errorcount = 0;
+- png_text software;
++ png_text comment, software;
+
+ /* these volatile declarations prevent gcc warnings ("variable might be
+ * clobbered by `longjmp' or `vfork'") */
+@@ -517,10 +517,15 @@
+ j = s->size;
+ if (j > 0 && data[j-1] == '\0') /* some apps include a NULL in GIF comment */
+ --j;
+- if (j<500) {
+- png_write_tEXt(png_ptr, "Comment", (png_charp)data, j);
++ if (j<1000) {
++ comment.compression = PNG_TEXT_COMPRESSION_NONE;
+ } else {
+- png_write_zTXt(png_ptr, "Comment", (png_charp)data, j, 0);
++ comment.compression = PNG_TEXT_COMPRESSION_zTXt;
++ comment.key = "Comment";
++ comment.text = data;
++ comment.text_length = j;
++
++ png_set_text(png_ptr, info_ptr, &comment, 1);
+ }
+ break;
+
================================================================
More information about the pld-cvs-commit
mailing list