From: Bart Van Assche Date: Sat, 4 Jul 2009 12:17:07 +0000 (+0000) Subject: Restored configure test for -Wno-empty-body. X-Git-Tag: svn/VALGRIND_3_5_0~440 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=16a8ccb5314fbc9025c566448e374d4bceadae9f;p=thirdparty%2Fvalgrind.git Restored configure test for -Wno-empty-body. git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10406 --- diff --git a/configure.in b/configure.in index b584f19377..c982457c46 100644 --- a/configure.in +++ b/configure.in @@ -1196,6 +1196,29 @@ if test x$declaration_after_statement = xyes; then fi +# does this compiler support -Wno-empty-body ? + +AC_MSG_CHECKING([if gcc accepts -Wno-empty-body]) + +safe_CFLAGS=$CFLAGS +CFLAGS="-Wno-empty-body" + +AC_TRY_COMPILE( +[ ], +[ + return 0; +], +[ +AC_SUBST([FLAG_W_NO_EMPTY_BODY], [-Wno-empty-body]) +AC_MSG_RESULT([yes]) +], +[ +AC_SUBST([FLAG_W_NO_EMPTY_BODY], []) +AC_MSG_RESULT([no]) +]) +CFLAGS=$safe_CFLAGS + + # does this compiler support -Wno-format-zero-length ? AC_MSG_CHECKING([if gcc accepts -Wno-format-zero-length])