configure: Move -Wno-maybe-uninitialized check into gcc section
authorDiego Biurrun <diego@biurrun.de>
Sat, 2 Nov 2013 11:16:00 +0000 (12:16 +0100)
committerDiego Biurrun <diego@biurrun.de>
Tue, 5 Nov 2013 11:22:48 +0000 (12:22 +0100)
As another example of bizarre compiler behavior clang groks the
-Wmaybe-uninitialized option, but not -Wno-maybe-uninitialized
and spews a warning for every file that gets compiled.

configure

index 4aa66c0..b83f9a3 100755 (executable)
--- a/configure
+++ b/configure
@@ -3924,7 +3924,6 @@ check_disable_warning -Wno-parentheses
 check_disable_warning -Wno-switch
 check_disable_warning -Wno-format-zero-length
 check_disable_warning -Wno-pointer-sign
-enabled extra_warnings || check_disable_warning -Wno-maybe-uninitialized
 
 # add some linker flags
 check_ldflags -Wl,--warn-common
@@ -4016,6 +4015,7 @@ elif enabled gcc; then
     check_cflags -Werror=return-type
     check_cflags -Werror=declaration-after-statement
     check_cflags -Werror=vla
+    enabled extra_warnings || check_disable_warning -Wno-maybe-uninitialized
 elif enabled llvm_gcc; then
     check_cflags -mllvm -stack-alignment=16
 elif enabled clang; then