Frederic Bouvier wrote:
> Melchior FRANZ wrote:
> > Why the #ifdef? Is there a reasonable case where CONFIG_H is *not*
> > available?
>
> It has always been the practice to enclose #include <config.h> by
> #ifdef HAVE_CONFIG_H from the beginning of autoconf/automake.

That's not really an answer to the question: do we or will we ever do
a build where there is no config.h?  Can such a build work even if we
tried it?  Based on your recent checking, the answer clearly seems to
be no.

Just drop the #ifdefs.  They're needless complexity, and using them
simply because "it's always been done that way" is bad software
engineering.

Andy

A lot of these are there because of cygwin wierdness. Without #include <config.h> in many files, building SimGear and FlightGear under CygWin breaks.

Rather than put the #ifdef in a file included by all of SimGear/ FlightGear source, isn't it easier/simpler to just put it where it is needed?

Would removing #ifdef HAVE_CONFIG_H/#endif wrappers break platforms that DON'T use autotools (maybe Windows without cygwin? I only build on windows with cygwin so I don't know the answer here).

Does <config.h> exist on ALL platforms even without autotools being used?

I'll gladly defer to others, I'd just prefer that CygWin and Mac OS X builds don't break... 8-)

Best regards,

Ima


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel

Reply via email to