Monday 07 January 2008 13:17:01 tarihinde Ralf Corsepius şunları yazmıştı: > On Mon, 2008-01-07 at 12:08 +0200, Ismail Dönmez wrote: > > Monday 07 January 2008 09:25:10 tarihinde şunları yazmıştınız: > > > On Sun, 2008-01-06 at 13:10 +0200, Ismail Dönmez wrote: > > > > Sunday 06 January 2008 08:30:14 tarihinde Paul Eggert şunları yazmıştı: > > > > > Ismail Dönmez <[EMAIL PROTECTED]> writes: > > > > > > but it should be defined like this, > > > > > > > > > > > > #ifndef FOO > > > > > > #define FOO > > > > > > #endif > > > > > > > > > > Why should it be defined like that? Typically, config.h is > > > > > supposed to define FOO; if something else is defining FOO first, > > > > > that's a problem with the "something else", not with config.h. > > > > > > > > Because otherwise it breaks with gcc 4.3 where FOO is defined > > > > multiple times, see > > > > http://www.cyrius.com/journal/gcc/gcc-4.3-pedwarn.html . I already > > > > hit this in multiple apps due to HAVE_STDLIB_H and such common config > > > > defs. > > > > > > So far, I've only seen this happening with packages which happen commit > > > the mistake to install config.h's or which expose supposed-to-be > > > private headers. > > > > > > Can you provide a real world example for which this happens? > > > > Sure, > > > > Breaks lots of apps via mpeg4ip package which installs a config.h > > "installs a config.h" > > => This package is broken. > > > and uses it > > through its headers though the file itself is private. > > > > Breaks again many apps via jconfig.h which is installed by jpeg package > > and used by headers. > > <sigh/> I had been waiting to this to be mentioned ;) > > libjpeg is known to be abusing the autotools and ignoring autotools' > working principles for many many years. It's time its upstream finally > fixes their package, or distros to abandon libjpeg. > > > I am sure more of this bugs are just hiding in the corner. > > Well, surely there are some, but ... > > Whether you like it or not, the packages you mention are simply broken. > > "Never install autoheaders, they are not supposed to be installed" has > been one of the fundamental working principles of autotool usage for > many years.
Isn't #ifndef , #define , #endif is the correct way to use anyway? Could you at least tell me where this is processed so I could get my hands dirty and fix it, maybe you'll accept it like that ;-) Regards, ismail -- Never learn by your mistakes, if you do you may never dare to try again.
