[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: gtk-peer compile fixes for gcc-2.95
From: |
Tom Tromey |
Subject: |
Re: gtk-peer compile fixes for gcc-2.95 |
Date: |
31 Mar 2004 16:36:26 -0700 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 |
Michael> CFLAGS=$CFLAGS -std=c89
Michael> AC_SUBST(CFLAGS)
Michael> This in configure.ac is another option.
Michael> The only problem I see is that we probably support non-gcc compilers
Michael> that dont support this flag. What will they do when they see it ?
CFLAGS is a user variable, setting it in configure.ac is GNU-ically
incorrect. It is better to set AM_CFLAGS instead. You can set this
in configure.ac just fine. There's also a standard trick for
handling gcc-specific options:
AM_CFLAGS=
if test "$GCC" = yes; then
AM_CFLAGS='-std=c89 -Wfoo -Wbar'
fi
AC_SUBST(AM_CFLAGS)
We set CFLAGS to -g in a specific case, that is sort of different
since it claims to work around bugs in the infamous gcc "2.96". I'd
prefer we avoid this in general.
Mark> But I had hoped Autoconf would make it easy to
Mark> specify the wanted C dialect.
As far as I know, there's no pre-made macro for this.
Tom