autoconf
[Top][All Lists]
Advanced

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

Re: Broken AC_TRY_COMPILE ?


From: gnutools
Subject: Re: Broken AC_TRY_COMPILE ?
Date: Wed, 12 Jun 2002 19:25:33 GMT+1

Okay, I decided to investigate this problem alone ;o)

The problem is that AC_TRY_COMPILE has been changed
between ac-2.13 and 2.5x releases. Actually it's
_AC_COMPILE_IFELSE from c.m4 which has been changed.

In 2.13 AC_TRY_COMPILE would fail if the compiler
does not recognize any CFLAGS. In 2.53, the test has
been changed to analyse the result of $? after
compiling and the presence of the conftest.o file.
Unfortunately this does not work any longer for
testing CFLAGS since some compiler (e.g GCC) will
compile even when some flags are unknown.

So I rewrote my macro to use something different
since AC_TRY_COMPILE is not appropriate anymore.
Basically I compile and grep the standard error
to check the presence of the flag in the error.
Fine.

Now there is another problem that comes out from
AC_PROG_CC which tests for the "-g" option. Basically
this test also use _AC_COMPILE_IFELSE as does
AC_TRY_COMPILE. So I guess if any compiler does
not actually support the "-g" option, the test
in AC_PROG_CC will not catch it.

Sorry for my monologues ;op
_________________________________________________________ 
Envoyez des messages musicaux sur le portable de vos amis 
 http://mobile.lycos.fr/mobile/local/sms_musicaux/


reply via email to

[Prev in Thread] Current Thread [Next in Thread]