Bring in the configure and makeopts jazz for -Wshadow, but don't add it to the
authorSean Bright <sean@malleable.com>
Fri, 8 Aug 2008 18:19:33 +0000 (18:19 +0000)
committerSean Bright <sean@malleable.com>
Fri, 8 Aug 2008 18:19:33 +0000 (18:19 +0000)
Makefile yet.

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@136819 65c4cc65-6c06-0410-ace0-fbb531ad65f3

configure
configure.ac
makeopts.in

index 33b3b31..ff4165f 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,5 +1,5 @@
 #! /bin/sh
-# From configure.ac Revision: 134650 .
+# From configure.ac Revision: 135405 .
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by GNU Autoconf 2.61 for asterisk 1.6.
 #
@@ -962,6 +962,7 @@ GC_CFLAGS
 GC_LDFLAGS
 AST_DECLARATION_AFTER_STATEMENT
 AST_NO_STRICT_OVERFLOW
+AST_SHADOW_WARNINGS
 PBX_RTLD_NOLOAD
 PBX_IP_MTU_DISCOVER
 GSM_INTERNAL
@@ -17265,9 +17266,9 @@ fi
 { echo "$as_me:$LINENO: checking for -fno-strict-overflow" >&5
 echo $ECHO_N "checking for -fno-strict-overflow... $ECHO_C" >&6; }
 if $(${CC} -O2 -fno-strict-overflow -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
-   { echo "$as_me:$LINENO: result: yes" >&5
+       { echo "$as_me:$LINENO: result: yes" >&5
 echo "${ECHO_T}yes" >&6; }
-   AST_NO_STRICT_OVERFLOW=-fno-strict-overflow
+       AST_NO_STRICT_OVERFLOW=-fno-strict-overflow
 else
        { echo "$as_me:$LINENO: result: no" >&5
 echo "${ECHO_T}no" >&6; }
@@ -17275,6 +17276,19 @@ echo "${ECHO_T}no" >&6; }
 fi
 
 
+{ echo "$as_me:$LINENO: checking for -Wshadow" >&5
+echo $ECHO_N "checking for -Wshadow... $ECHO_C" >&6; }
+if $(${CC} -Wshadow -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
+       { echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
+       AST_SHADOW_WARNINGS=-Wshadow
+else
+       { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+       AST_SHADOW_WARNINGS=
+fi
+
+
 { echo "$as_me:$LINENO: checking for sysinfo" >&5
 echo $ECHO_N "checking for sysinfo... $ECHO_C" >&6; }
 cat >conftest.$ac_ext <<_ACEOF
@@ -50929,6 +50943,7 @@ GC_CFLAGS!$GC_CFLAGS$ac_delim
 GC_LDFLAGS!$GC_LDFLAGS$ac_delim
 AST_DECLARATION_AFTER_STATEMENT!$AST_DECLARATION_AFTER_STATEMENT$ac_delim
 AST_NO_STRICT_OVERFLOW!$AST_NO_STRICT_OVERFLOW$ac_delim
+AST_SHADOW_WARNINGS!$AST_SHADOW_WARNINGS$ac_delim
 PBX_RTLD_NOLOAD!$PBX_RTLD_NOLOAD$ac_delim
 PBX_IP_MTU_DISCOVER!$PBX_IP_MTU_DISCOVER$ac_delim
 GSM_INTERNAL!$GSM_INTERNAL$ac_delim
@@ -50961,7 +50976,7 @@ CURL_CONFIG!$CURL_CONFIG$ac_delim
 LTLIBOBJS!$LTLIBOBJS$ac_delim
 _ACEOF
 
-  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 82; then
+  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 83; then
     break
   elif $ac_last_try; then
     { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
index 1188619..b0dee0f 100644 (file)
@@ -491,14 +491,24 @@ AC_SUBST(AST_DECLARATION_AFTER_STATEMENT)
 
 AC_MSG_CHECKING(for -fno-strict-overflow)
 if $(${CC} -O2 -fno-strict-overflow -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
-   AC_MSG_RESULT(yes)
-   AST_NO_STRICT_OVERFLOW=-fno-strict-overflow
+       AC_MSG_RESULT(yes)
+       AST_NO_STRICT_OVERFLOW=-fno-strict-overflow
 else
        AC_MSG_RESULT(no)
        AST_NO_STRICT_OVERFLOW=
 fi
 AC_SUBST(AST_NO_STRICT_OVERFLOW)
 
+AC_MSG_CHECKING(for -Wshadow)
+if $(${CC} -Wshadow -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
+       AC_MSG_RESULT(yes)
+       AST_SHADOW_WARNINGS=-Wshadow
+else
+       AC_MSG_RESULT(no)
+       AST_SHADOW_WARNINGS=
+fi
+AC_SUBST(AST_SHADOW_WARNINGS)
+
 AC_MSG_CHECKING(for sysinfo)
 AC_LINK_IFELSE(
         AC_LANG_PROGRAM([#include <sys/sysinfo.h>],
index 96fe081..57d7fed 100644 (file)
@@ -65,6 +65,7 @@ AST_DEVMODE=@AST_DEVMODE@
 
 AST_DECLARATION_AFTER_STATEMENT=@AST_DECLARATION_AFTER_STATEMENT@
 AST_NO_STRICT_OVERFLOW=@AST_NO_STRICT_OVERFLOW@
+AST_SHADOW_WARNINGS=@AST_SHADOW_WARNINGS@
 
 ASOUND_INCLUDE=@ALSA_INCLUDE@
 ASOUND_LIB=@ALSA_LIB@