Commit c8b2591a authored by Max Kellermann's avatar Max Kellermann

configure.ac: move -Werror before all other CFLAGS

Without -Werror, clang will not fail on -ftree-vectorize.
parent ee1d8e10
...@@ -1463,6 +1463,13 @@ dnl --------------------------------------------------------------------------- ...@@ -1463,6 +1463,13 @@ dnl ---------------------------------------------------------------------------
dnl CFLAGS dnl CFLAGS
dnl --------------------------------------------------------------------------- dnl ---------------------------------------------------------------------------
dnl ---------------------------- warnings as errors ---------------------------
if test "x$enable_werror" = xyes; then
CFLAGS="$CFLAGS -Werror -pedantic-errors"
CXXFLAGS="$CXXFLAGS -Werror"
fi
dnl ---------------------------- language features ----------------------------
AX_APPEND_COMPILE_FLAGS([-fvisibility=hidden]) AX_APPEND_COMPILE_FLAGS([-fvisibility=hidden])
AX_APPEND_COMPILE_FLAGS([-ffast-math]) AX_APPEND_COMPILE_FLAGS([-ffast-math])
AX_APPEND_COMPILE_FLAGS([-ftree-vectorize]) AX_APPEND_COMPILE_FLAGS([-ftree-vectorize])
...@@ -1517,12 +1524,6 @@ then ...@@ -1517,12 +1524,6 @@ then
AC_LANG_POP AC_LANG_POP
fi fi
dnl ---------------------------- warnings as errors ---------------------------
if test "x$enable_werror" = xyes; then
AM_CFLAGS="$AM_CFLAGS -Werror -pedantic-errors"
AM_CXXFLAGS="$AM_CXXFLAGS -Werror"
fi
dnl --------------------------------------------------------------------------- dnl ---------------------------------------------------------------------------
dnl Pretty-Print Results dnl Pretty-Print Results
dnl --------------------------------------------------------------------------- dnl ---------------------------------------------------------------------------
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment