Community Packages

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#18091 - [php52] GD won't complie against libpng 1.4.0

Attached to Project: Community Packages
Opened by Chen-sheng Lin (Hipfox) - Sunday, 31 January 2010, 17:56 GMT
Last edited by Evangelos Foutras (foutrelis) - Sunday, 31 January 2010, 22:30 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Evangelos Foutras (foutrelis)
Architecture All
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
From the libpng README at
ftp://ftp.simplesystems.org/pub/libpng/png/src/libpng-1.4.0-README.txt :
"Removed the deprecated png_check_sig() function/macro."

The file ext/gd/libgd/gd_png.c currently uses this function and so will
not compile against libpng 1.4.0. The libpng man page notes the
following:

"The function
png_check_sig(sig, num) was replaced with
!png_sig_cmp(sig, 0, num) It has been deprecated since libpng-0.90."

To see detail: http://aspn.activestate.com/ASPN/Mail/Message/php-dev/3803631

Additional info:
php52 5.2.12-2


Steps to reproduce:
>: php -v
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/20060613/gd.so' - /usr/lib/php/20060613/gd.so: undefined symbol: png_check_sig in Unknown on line 0
PHP 5.2.12 with Suhosin-Patch 0.9.7 (cli) (built: Jan 19 2010 22:50:02)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies


This task depends upon

Closed by  Evangelos Foutras (foutrelis)
Sunday, 31 January 2010, 22:30 GMT
Reason for closing:  Fixed
Additional comments about closing:  php52 5.2.12-3
Comment by Chen-sheng Lin (Hipfox) - Sunday, 31 January 2010, 18:08 GMT
I made the following change in ext/gd/libgd/gd_png.c and php re-compiled successfully.

- if (!png_check_sig (sig, 8)) { /* bad signature */
+ if (png_sig_cmp (sig, 0, 8)) { /* bad signature */
return NULL;
}

but I still do not known how to write patch in PKGBUILD.
Comment by Evangelos Foutras (foutrelis) - Sunday, 31 January 2010, 20:19 GMT
Thanks for the very detailed report. I will fix this immediately.

Loading...