/usr/include/jconfig.h contains two internal macros that aren't part of the ABI/API and shouldn't be exposed in public headers. HAVE_STDLIB_H and HAVE_STDDEF_H are common autoconf defines used in the configuring of libjpeg. The result of having them exposed in jconfig.h is that any package including jpeglib.h (which includes jconfig.h) and defining HAVE_STDLIB_H or HAVE_STDDEF_H through autoconf will get a warning like: In file included from FlateStream.h:11, from Stream.cc:41: ../config.h:66:1: warning: "HAVE_STDLIB_H" redefined In file included from /usr/include/jpeglib.h:28, from DCTStream.h:39, from Stream.cc:37: /usr/include/jconfig.h:12:1: warning: this is the location of the previous definition In GCC 4.3, this becomes an error, preventing several packages from building. The fix for this is to remove the two defines from jconfig.h. Debian has been doing this since 2002, and the LSB also published an errata for their specification last year to removes them. http://packages.debian.org/changelogs/pool/main/libj/libjpeg6b/libjpeg6b_6b-13/changelog#year2002 http://bugs.linuxbase.org/attachment.cgi?id=281
Current GCC svn reverts the change that made redefinitions errors. See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24924. Any checkout after -r131530 (14 Jan 2008) will work. So I guess we could close this, though we might hit it again in the future. I never did figure out why this case causes problems when others with near-identical circumstances (like mpeg4ip) don't. Dumb luck i guess.
you're right it's a bug regardless of how gcc treats it ... the header sucks most likely i'm not going to fix this in Gentoo ... i submitted a project request to freedesktop.org to get a jpeg maintainer project going there, so i'm holding off on doing major build-system fixes until then at which point i'd release a new tarball rather than a huge fugly patch
This doesn't block gcc-4.3 anymore. It works fine.
Closing.