1
0
mirror of https://github.com/osmarks/ngircd.git synced 2024-12-15 03:10:27 +00:00

Disabling "-ansi" on Cygwin: system headers are incompatible.

This commit is contained in:
Alexander Barton 2003-04-25 15:02:15 +00:00
parent 14b1ae7aea
commit 99ab8607c9

View File

@ -8,7 +8,7 @@
# (at your option) any later version. # (at your option) any later version.
# Please read the file COPYING, README and AUTHORS for more information. # Please read the file COPYING, README and AUTHORS for more information.
# #
# $Id: configure.in,v 1.89.2.3 2003/04/23 01:15:20 alex Exp $ # $Id: configure.in,v 1.89.2.4 2003/04/25 15:02:15 alex Exp $
# #
# -- Initialisierung -- # -- Initialisierung --
@ -266,15 +266,26 @@ AC_DEFINE_UNQUOTED(TARGET_OS, "$target_os" )
if test "$GCC" = "yes"; then if test "$GCC" = "yes"; then
the_CFLAGS="-Wmissing-declarations -Wpointer-arith -Wstrict-prototypes" the_CFLAGS="-Wmissing-declarations -Wpointer-arith -Wstrict-prototypes"
ansi=" -ansi"
pedantic=" -pedantic"
$CC --version | grep 20020420 > /dev/null 2>&1 $CC --version | grep 20020420 > /dev/null 2>&1
if test $? -eq 0; then if test $? -eq 0; then
# Mac OS X (and Darwin?) ship with a slightly broken # Mac OS X (and Darwin?) ship with a slightly broken
# prerelease of GCC 3.1 which don't like -pedantic: # prerelease of GCC 3.1 which don't like -pedantic:
AC_MSG_RESULT([detected broken GNU C compiler, disabling "-pedantic"]) AC_MSG_RESULT([detected broken GNU C compiler, disabling "-pedantic"])
add_CFLAGS="-Wall -W -ansi $CFLAGS $CFLAGS_ADD" pedantic=""
else
add_CFLAGS="-Wall -W -ansi -pedantic $CFLAGS $CFLAGS_ADD"
fi fi
uname | grep "CYGWIN" > /dev/null 2>&1
if test $? -eq 0; then
# The include files of Cygwin don't like -ansi,
# so we disable it:
AC_MSG_RESULT([detected Cygwin, disabling "-ansi"])
ansi=""
fi
add_CFLAGS="-Wall -W${ansi}${pedantic} $CFLAGS $CFLAGS_ADD"
else else
the_CFLAGS="$CFLAGS" the_CFLAGS="$CFLAGS"
add_CFLAGS="$CFLAGS_ADD" add_CFLAGS="$CFLAGS_ADD"