From: David Woodhouse Date: Mon, 29 Mar 2021 10:17:21 +0000 (+0100) Subject: Turn off -Wdeclaration-after-statement and allow C99 X-Git-Tag: v8.20~332 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=d7a8f8d73a824808a63fc8f8a8d11e901b09e705;p=users%2Fdwmw2%2Fopenconnect.git Turn off -Wdeclaration-after-statement and allow C99 I think this far into the 21st century we can allow declarations to be in the middle of code blocks. Even MSVC supports that, even if it doesn't do other parts of C99 like named struct initialisers. Signed-off-by: David Woodhouse --- diff --git a/configure.ac b/configure.ac index 8dc46994..bdb1138b 100644 --- a/configure.ac +++ b/configure.ac @@ -31,6 +31,7 @@ symver_win32_strerror= # is conditional (as it is here for some of the MinGW checks), it forgets # to ever look for one in the other code paths. Do it explicitly here. AC_PROG_CC +AC_PROG_CC_C99 case $host_os in *linux* | *gnu* | *nacl*) @@ -181,7 +182,6 @@ AS_COMPILER_FLAGS(WFLAGS, -Wno-sign-compare -Wno-unused-parameter -Werror=pointer-to-int-cast - -Wdeclaration-after-statement -Werror-implicit-function-declaration -Wformat-nonliteral -Wformat-security