I've just tried to build enblend 4.0 with the latest release of
libpng. It fails:
g++46 -DHAVE_CONFIG_H -I. -I../.. -I/usr/local/include -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -I../../include -DVIGRA_STATIC_LIB -D_THREAD_SAFE -I/usr/local/include/OpenEXR -O2 -pipe -Wl,-rpath=/usr/local/lib/gcc46 -fno-strict-aliasing --param inline-unit-growth=60 -O2 -DNDEBUG -Wall -MT libvigra_impex_a-png.o -MD -MP -MF .deps/libvigra_impex_a-png.Tpo -c -o libvigra_impex_a-png.o `test -f 'png.cxx' || echo './'`png.cxx
png.cxx: In function 'void PngError(png_structp, png_const_charp)':
png.cxx:84:21: error: invalid use of incomplete type 'png_struct {aka struct png_struct_def}'
/usr/local/include/png.h:872:16: error: forward declaration of 'png_struct {aka struct png_struct_def}'
png.cxx: In constructor 'vigra::PngDecoderImpl::PngDecoderImpl(const string&)':
(many more such messages follow)
This seems to be a deliberate decision on the part of the authors of
libpng. At
http://www.libpng.org/pub/png/libpng.html there's a
notice:
Portability Note
The libpng 1.5.x series continues the evolution of the libpng API,
finally hiding the contents of the venerable and hoary png_struct
and png_info data structures inside private (i.e., non-installed)
header files. Instead of direct struct-access, applications should
be using the various png_get_xxx() and png_set_xxx() accessor
functions, which have existed for almost as long as libpng
itself. (Apps that compiled against libpng 1.4 without warnings
about deprecated features should happily compile against 1.5,
too.)
I haven't found any mention of this problem on this mailing list. The
only thing I found is
https://groups.google.com/forum/?fromgroups#!searchin/hugin-ptx/enblend$20png_struct|sort:date/hugin-ptx/lvPmeMxAO7w/O7ZuINL0shQJ
(is there really no way of getting a shorter link?), referring to 1.4
and the "deprecated" warnings. Has anybody done anything about this?
Otherwise I'll have a go. I don't see reverting to libpng 1.4 as a
solution.
Greg
--
Sent from my desktop computer.
Finger gr...@FreeBSD.org for PGP public key.
See complete headers for address and phone numbers.
This message is digitally signed. If your Microsoft MUA reports
problems, please read
http://tinyurl.com/broken-mua