This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: gcc 3.2's cpp breaks configure scripts

Roger Corman writes:
>     It seems somewhat ludicrous that the idea of an option to disable
> the spewing of the message, which breaks a significant number of
> configure scripts, is shunned.  "Let's break lots of code and expect
> everyone else to fix their stuff and not provide any sort of work
> around".  Pretty pathetic.

It does appear to be one of the few gcc warnings that cannot be suppressed
by any means; it will appear unconditionally.  This breakage may be bad
enough that distributors will come up with their own patch, otherwise how
can they hope to put together a distribution with 500 distinct examples of
this breakage.

How about this idea: an option that tells gcc simply to ignore any -I
lines that refer to system directories.  This seems to me to be exactly
what is wanted for gcc command lines generated by configure.  If such an
option existed,

CC="gcc -fignore-system-include-dirs" configure

would work.  The effect of

(csh/tcsh users would type

env CC="gcc -fignore-system-include-dirs" configure



gcc -fignore-system-include-dirs -I/usr/include -I/some/place -O2 -c foo.c

would simply be identical to

gcc -I/some/place -O2 -c foo.c

Sure, it's a hack, but it will allow people to build old apps.  The
nice thing about this is that it will avoid the problems that motivated
the warning in the first place, that is, that if the search order for
system directories is changed things like #include_next break and
fixincluded headers can be bypassed.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]