From cd0ceac29999d6b121c5d6d7628648320348b4b4 Mon Sep 17 00:00:00 2001 From: Taylor R Campbell Date: Wed, 7 Nov 2018 16:27:44 +0000 Subject: [PATCH] Add -Werror after all autoconf checks. If we do it before, the autoconf checks -- which are full of compiler warnings -- all fail. --- src/microcode/configure.ac | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/microcode/configure.ac b/src/microcode/configure.ac index 337c9ea96..31fd4af50 100644 --- a/src/microcode/configure.ac +++ b/src/microcode/configure.ac @@ -210,6 +210,7 @@ if test ${GCC} = yes; then fi CFLAGS="-Wall -Wundef -Wpointer-arith -Winline ${CFLAGS}" CFLAGS="-Wstrict-prototypes -Wnested-externs -Wredundant-decls ${CFLAGS}" + CFLAGS_WERROR=-Werror AC_MSG_CHECKING([for GCC>=4]) AC_COMPILE_IFELSE( @@ -861,6 +862,8 @@ for base in ${OPTIONAL_BASES}; do OPTIONAL_OBJECTS="${OPTIONAL_OBJECTS} ${base}.o" done +CFLAGS="${CFLAGS} ${CFLAGS_WERROR}" + AC_SUBST([AS_FLAGS]) AC_SUBST([GC_HEAD_FILES]) AC_SUBST([M4_FLAGS]) -- 2.25.1