Re: best way to check for compiler _warnings_?

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

 



* Miles Bader wrote on Tue, Nov 02, 2010 at 04:34:43AM CET:
> Ralf Wildenhues writes:
> > 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?

No.

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

Yes, that is a good idea.

> 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.

Except then you may run into MSVC which prints its command-line options
(dunno whether on stdout or stderr) ...

Cheers,
Ralf

_______________________________________________
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