X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/e3bc07123db69275fd073a4dec1c5eb803fd9b45..d8cefbe067bef21ae9819aee7ec57e74c2f80340:/acmacro/compiler-flags.m4 diff --git a/acmacro/compiler-flags.m4 b/acmacro/compiler-flags.m4 index 01bd8fbe59..2b6672c78e 100644 --- a/acmacro/compiler-flags.m4 +++ b/acmacro/compiler-flags.m4 @@ -19,8 +19,9 @@ AC_DEFUN([GNOME_COMPILE_WARNINGS],[ ## with individual -Wno-xxx flags, unlike -Wall if test "x$enable_compile_warnings" = "xyes"; then warnCFLAGS="$warnCFLAGS -Wmissing-prototypes -Wmissing-declarations \ - -finline-functions -Wshadow -Wpointer-arith -Wchar-subscripts \ - -Wformat=2 -Wno-unused-variable -Wno-unused-function -Wwrite-strings -Werror" + -finline-functions -Wshadow -Wpointer-arith -Wchar-subscripts -Wcomment \ + -Wformat=2 -Wno-unused-variable -Wno-unused-function -Wwrite-strings \ + -Werror" fi fi @@ -52,18 +53,18 @@ AC_DEFUN([GNOME_COMPILE_WARNINGS],[ optCFLAGS="-ffast-math -funroll-loops -fno-strict-aliasing" case " $CFLAGS " in *-O*) ;; - *) optCFLAGS="-03" ;; + *) optCFLAGS="$optCFLAGS -03" ;; esac fi - AC_MSG_RESULT($complCFLAGS) + AC_MSG_RESULT($optCFLAGS) # Take the right flags if test "x$cflags_set" != "xyes" ; then if test "x$enable_iso_c" != "xno"; then - CFLAGS="$CFLAGS $complCFLAGS" + CFLAGS="$CFLAGS $complCFLAGS $optCFLAGS" fi if test "x$enable_compile_warnings" != "xno" ; then - CFLAGS="$CFLAGS $warnCFLAGS" + CFLAGS="$CFLAGS $warnCFLAGS $optCFLAGS" fi cflags_set=yes