summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorNorbert Thiebaud <nthiebaud@gmail.com>2011-07-26 21:58:08 -0500
committerNorbert Thiebaud <nthiebaud@gmail.com>2011-07-26 21:58:08 -0500
commitb5e6d0a679ec3f80cae781c93fe7d728dd53b58e (patch)
treeb0e2f0fd030f792733c1ebf705c2b95f3e0e70bd /configure.in
parent82f0ba7e98430b5a7df740f8a4f5b5e02e54c1eb (diff)
make -Wno-long-double usage conditional to gcc supporting it
Diffstat (limited to 'configure.in')
-rwxr-xr-xconfigure.in12
1 files changed, 12 insertions, 0 deletions
diff --git a/configure.in b/configure.in
index d69a89d59f61..e5632cda4d54 100755
--- a/configure.in
+++ b/configure.in
@@ -3193,6 +3193,17 @@ if test "$GCC" = "yes"; then
AC_MSG_RESULT([no])
fi
+ AC_MSG_CHECKING([whether $CC supports -Wno-long-double])
+ save_CFLAGS=$CFLAGS
+ CFLAGS="$CFLAGS -Werror -Wno-long-double"
+ AC_TRY_LINK([], [ return 0; ], [ HAVE_GCC_NO_LONG_DOUBLE=TRUE ], [])
+ CFLAGS=$save_CFLAGS
+ if test "$HAVE_GCC_NO_LONG_DOUBLE" = "TRUE"; then
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no])
+ fi
+
AC_MSG_CHECKING([whether $CC supports -std=c++0x without Language Defect 757])
save_CXXFLAGS=$CFLAGS
CXXFLAGS="$CXXFLAGS -std=c++0x"
@@ -3234,6 +3245,7 @@ return !(i != 0 && j != 0);
fi
AC_SUBST(HAVE_CXX0X)
+AC_SUBST(HAVE_GCC_NO_LONG_DOUBLE)
# ===================================================================
# use ccache?