diff --git a/configure.ac b/configure.ac index c73f66b6..b3cb13a9 100644 --- a/configure.ac +++ b/configure.ac @@ -306,11 +306,10 @@ AS_CASE([$host_os], ]) ]) -AC_ARG_VAR([CWFLAGS], [define to compilation flags for generating extra warnings]) - AX_CHECK_COMPILE_FLAG([$CFLAGS -Wall], [CWFLAGS="$CFLAGS -Wall"]) -AX_CHECK_COMPILE_FLAG([$CFLAGS -Wextra], [CWFLAGS="$CFLAGS -Wextra"]) -AX_CHECK_COMPILE_FLAG([$CFLAGS -Wno-deprecated-declarations], [CWFLAGS="$CFLAGS -Wno-deprecated-declarations"]) +AX_CHECK_COMPILE_FLAG([$CFLAGS -Wno-deprecated-declarations], [CFLAGS="$CFLAGS -Wno-deprecated-declarations"]) + +AC_ARG_VAR([CWFLAGS], [compilation flags for generating extra warnings]) AC_MSG_CHECKING(for clang) AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ @@ -325,6 +324,7 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ [AC_MSG_RESULT(no) ]) +AX_CHECK_COMPILE_FLAG([$CWFLAGS -Wextra], [CWFLAGS="$WCFLAGS -Wextra"]) AX_CHECK_COMPILE_FLAG([$CWFLAGS -Warray-bounds], [CWFLAGS="$CWFLAGS -Warray-bounds"]) AX_CHECK_COMPILE_FLAG([$CWFLAGS -Wbad-function-cast], [CWFLAGS="$CWFLAGS -Wbad-function-cast"]) AX_CHECK_COMPILE_FLAG([$CWFLAGS -Wcast-qual], [CWFLAGS="$CWFLAGS -Wcast-qual"])