I think this is handled in scripts/options.awk which is a little difficult for me to follow. I wonder if the problem goes away if you add some parentheses in pngpriv.h line 910 so it reads #if (PNG_ZLIB_VERNUM != 0) && (PNG_ZLIB_VERNUM != ZLIB_VERNUM)
Confirmed that this test segfaults for me.
This is not a terribly satisfactory solution, but you may be able to work around the problem by using --zprefix when you configure your new zlib. This may eliminate a conflict between your new zlib with the older one lurking on your system somewhere.
This is not a terribly satisfactory solution, but you may be able to work around the problem by using --zprefix when you configure your new zlib. This may eliminate a conflict between your new zlib with the older one lurking on your system somewhere.
1.6.33 testsuite failures
The troublesome new interlaced files have been removed from contrib/pngsuite in libpng-1.6.34.
Thanks for the report. I removed the new interlaced images from libpng-1.6.34, and put some of them back in libpng-1.6.35beta01 (omitting the ones that were rejected by pngimage. As far as I can tell there is nothing wrong with them, but it appears that "pngimage" is having trouble with interlaced images that have bit-depth less than 8.
png_do_check_palette_indexes seems out of bounds