flac configury does a XIPH_ADD_CFLAGS([-Wextra]) around line 426,
however it unconditionally adds -Wextra some lines before that too.
The attached patch removes that unconditional addition of -Wextra
which (i) removes duplicate addition, and (ii) allows older gcc
versions to compile the tree peacefully. Please consider applying.
--
O.S.
-------------- next part --------------
diff --git a/configure.ac b/configure.ac
index 99c471d..2ee2be0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -380,8 +380,8 @@ fi
XIPH_GCC_VERSION
if test x$ac_cv_c_compiler_gnu = xyes ; then
- CFLAGS="$CFLAGS -Wall -Wextra -Wstrict-prototypes -Wmissing-prototypes
-Waggregate-return -Wcast-align -Wnested-externs -Wshadow -Wundef
-Wmissing-declarations -Wunreachable-code -Winline " # -Wcast-qual
-Wbad-function-cast -Wwrite-strings -Wconversion
- CXXFLAGS="$CXXFLAGS -Wall -Wextra -Wcast-align -Wshadow -Wwrite-strings
-Wctor-dtor-privacy -Wnon-virtual-dtor -Wreorder -Wsign-promo -Wundef
-Wunreachable-code " # -Wcast-qual -Wbad-function-cast -Wwrite-strings
-Woverloaded-virtual -Wmissing-declarations
+ CFLAGS="$CFLAGS -Wall -Wstrict-prototypes -Wmissing-prototypes
-Waggregate-return -Wcast-align -Wnested-externs -Wshadow -Wundef
-Wmissing-declarations -Wunreachable-code -Winline " # -Wcast-qual
-Wbad-function-cast -Wwrite-strings -Wconversion
+ CXXFLAGS="$CXXFLAGS -Wall -Wcast-align -Wshadow -Wwrite-strings
-Wctor-dtor-privacy -Wnon-virtual-dtor -Wreorder -Wsign-promo -Wundef
-Wunreachable-code " # -Wcast-qual -Wbad-function-cast -Wwrite-strings
-Woverloaded-virtual -Wmissing-declarations
XIPH_ADD_CFLAGS([-Wdeclaration-after-statement])
XIPH_ADD_CFLAGS([-D_FORTIFY_SOURCE=2])