Re: best way to check for compiler _warnings_?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ralf Wildenhues <Ralf.Wildenhues@xxxxxx> writes:
> First, please complain to the compiler vendor (whoever is responsible
> for the behavior).  FWIW, I can reproduce with Debian GCC 4.3.5 but not
> with upstream FSF GCC from SVN.

Sure, I understand, but quite a bit of my configure.ac files seem to be
devoted to working around others' mistakes... :)

[That seems to be one reason why autoconf is so nice -- it allows one to
deal with the way things _really_ are rather than the way things should
be.]

> Then, dealing with such behavior is tricky in general.  You can use
> AC_LANG_WERROR, but it has problems if the compiler is verbose by
> default.  Libtool has a couple of macros that test a compiler without
> and with some flag and compare output of the two, but even that is of
> limited reliability if the "normal" part of the output is noisy.  It's
> a mess.

Is there something like "AC_GREP_COMPILATION", i.e., that just runs the
compiler as if for AC_COMPILE_IFELSE, and gives you the output
untouched?

Hmm, I suppose I should look at how AC_COMPILE_IFELSE is implemented...

My thought currently is that I could run the compiler and then grep for
the option name in the output; if it occurs, it's pretty likely because
of an error/warning messages, and seems like it might avoid most
false negatives.

Thanks,

-Miles

-- 
Friendship, n. A ship big enough to carry two in fair weather, but only one
in foul.


_______________________________________________
Autoconf mailing list
Autoconf@xxxxxxx
http://lists.gnu.org/mailman/listinfo/autoconf


[Index of Archives]     [GCC Help]     [Kernel Discussion]     [RPM Discussion]     [Red Hat Development]     [Yosemite News]     [Linux USB]     [Samba]

  Powered by Linux