GNOME Bugzilla – Bug 607242
GIMP 2.7.0 fails to build against libpng 1.4.0
Last modified: 2010-06-20 14:59:58 UTC
GIMP 2.7.0 fails to build against libpng 1.4.0: make[3]: Entering directory `/home/skottish/pkgbuilds/gimp-devel/src/gimp-2.7.0/plug-ins/file-ico' CC file_ico-ico.o CC file_ico-ico-dialog.o CC file_ico-ico-load.o ico-load.c: In function ‘ico_read_png’: ico-load.c:289: warning: implicit declaration of function ‘png_set_gray_1_2_4_to_8’ CC file_ico-ico-save.o CCLD file-ico file_ico-ico-load.o: In function `ico_read_png': ico-load.c:(.text+0x399): undefined reference to `png_set_gray_1_2_4_to_8' ico-load.c:(.text+0x42d): undefined reference to `png_set_gray_1_2_4_to_8' collect2: ld returned 1 exit status make[3]: *** [file-ico] Error 1 make[3]: Leaving directory `/home/skottish/pkgbuilds/gimp-devel/src/gimp-2.7.0/plug-ins/file-ico' make[2]: *** [all-recursive] Error 1 -->><<-- 64 bit Arch Linux gcc 4.4.2-4 binutils 2.20-3
http://www.libpng.org/pub/png/src/libpng-1.2.x-to-1.4.x-summary.txt " m. The function png_set_gray_1_2_4_to_8() was removed. It has been deprecated since libpng-1.0.18 and 1.2.9, when it was replaced with png_set_expand_gray_1_2_4_to_8() because the former function also expanded palette images." Do you want to provide the patch (against git, if possible)?
Created attachment 151806 [details] [review] libpng 1.4 patch against gimp 2.7.0
Review of attachment 151806 [details] [review]: This function has been deprecated for some time, maybe this can even be replaced unconditionally? And can you provide a git-formatted patch?
(In reply to comment #3) > can you provide a git-formatted patch? See http://live.gnome.org/Git/Developers
Fixed differently in master: commit 2db98792dcb466ef432ffe15a249466609beba45 Author: Michael Natterer <mitch@gimp.org> Date: Sun Jan 31 11:56:36 2010 +0100 Bug 607242 - GIMP 2.7.0 fails to build against libpng 1.4.0 Depend on the libpng version that is in debian testing (1.2.42) and use png_set_expand_gray_1_2_4_to_8() instead of the deprecated png_set_gray_1_2_4_to_8(). configure.ac | 3 ++- plug-ins/file-ico/ico-load.c | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-)
Fixed in 2.6 too, using a slightly changed version of the attached patch: commit b22eb0a8271a99257fe214cbf0adda29cf9a39dd Author: Michael Natterer <mitch@gimp.org> Date: Sun Jan 31 12:28:02 2010 +0100 Bug 607242 - GIMP 2.7.0 fails to build against libpng 1.4.0 Use png_set_expand_gray_1_2_4_to_8() instead of the deprecated png_set_gray_1_2_4_to_8() if libpng is at least 1.2.27 (which is in debian stable), so plug-ins built against old versions contine to work when libpng 1.4 gets installed. plug-ins/file-ico/ico-load.c | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-)
*** Bug 622198 has been marked as a duplicate of this bug. ***