projects
/
mesa.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
m4: add Werror when checking for compiler flags
[mesa.git]
/
configure.ac
diff --git
a/configure.ac
b/configure.ac
index 156fb15fd3d51ce48703be6cefc5fe305dc1e7be..be9674a0c1db42121b2734cc324f62c786f2347f 100644
(file)
--- a/
configure.ac
+++ b/
configure.ac
@@
-297,6
+297,12
@@
esac
AM_CONDITIONAL(HAVE_ANDROID, test "x$android" = xyes)
AM_CONDITIONAL(HAVE_ANDROID, test "x$android" = xyes)
+# Toggle Werror since at some point clang started treating unknown -W
+# flags as warnings, succeeding with the build, yet issuing an annoying
+# warning.
+save_CFLAGS="$CFLAGS"
+export CFLAGS="$CFLAGS -Werror"
+
dnl
dnl Check compiler flags
dnl
dnl
dnl Check compiler flags
dnl
@@
-312,6
+318,11
@@
AX_CHECK_COMPILE_FLAG([-fno-math-errno], [CFLAGS="$CFLAGS
AX_CHECK_COMPILE_FLAG([-fno-trapping-math], [CFLAGS="$CFLAGS -fno-trapping-math"])
AX_CHECK_COMPILE_FLAG([-fvisibility=hidden], [VISIBILITY_CFLAGS="-fvisibility=hidden"])
AX_CHECK_COMPILE_FLAG([-fno-trapping-math], [CFLAGS="$CFLAGS -fno-trapping-math"])
AX_CHECK_COMPILE_FLAG([-fvisibility=hidden], [VISIBILITY_CFLAGS="-fvisibility=hidden"])
+CFLAGS="$save_CFLAGS"
+
+# Toggle Werror since at some point clang started treating unknown -W
+# flags as warnings, succeeding with the build, yet issuing an annoying
+# warning.
dnl
dnl Check C++ compiler flags
dnl
dnl
dnl Check C++ compiler flags
dnl