From 5578b9a88916474774fbc54c8f985a4600d32f9e Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Wed, 14 Feb 2007 23:17:48 +0000 Subject: [PATCH] fix configure test failure if -Werror is in CFLAGS git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4280 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- libs/js/configure | 51 +++++++++++++++++++++++--------------------- libs/js/configure.ac | 3 +++ 2 files changed, 30 insertions(+), 24 deletions(-) diff --git a/libs/js/configure b/libs/js/configure index 12a6288470..36e4ede17b 100755 --- a/libs/js/configure +++ b/libs/js/configure @@ -3580,6 +3580,8 @@ echo "${ECHO_T}no (using fallback implementation)" >&6 fi +OLD_CFLAGS="$CFLAGS" +CFLAGS="" echo "$as_me:$LINENO: checking for gethostname in -lnsl" >&5 echo $ECHO_N "checking for gethostname in -lnsl... $ECHO_C" >&6 @@ -3878,6 +3880,7 @@ _ACEOF fi +CFLAGS="$OLD_CFLAGS" echo "$as_me:$LINENO: checking for struct stat.st_birthtime" >&5 echo $ECHO_N "checking for struct stat.st_birthtime... $ECHO_C" >&6 @@ -6560,7 +6563,7 @@ ia64-*-hpux*) ;; *-*-irix6*) # Find out which ABI we are using. - echo '#line 6563 "configure"' > conftest.$ac_ext + echo '#line 6566 "configure"' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? @@ -7577,7 +7580,7 @@ fi # Provide some information about the compiler. -echo "$as_me:7580:" \ +echo "$as_me:7583:" \ "checking for Fortran 77 compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (eval echo "$as_me:$LINENO: \"$ac_compiler --version &5\"") >&5 @@ -8644,11 +8647,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:8647: $lt_compile\"" >&5) + (eval echo "\"\$as_me:8650: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:8651: \$? = $ac_status" >&5 + echo "$as_me:8654: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -8912,11 +8915,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:8915: $lt_compile\"" >&5) + (eval echo "\"\$as_me:8918: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:8919: \$? = $ac_status" >&5 + echo "$as_me:8922: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -9016,11 +9019,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9019: $lt_compile\"" >&5) + (eval echo "\"\$as_me:9022: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:9023: \$? = $ac_status" >&5 + echo "$as_me:9026: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -11361,7 +11364,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext < conftest.$ac_ext <&5) + (eval echo "\"\$as_me:13811: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:13812: \$? = $ac_status" >&5 + echo "$as_me:13815: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -13909,11 +13912,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:13912: $lt_compile\"" >&5) + (eval echo "\"\$as_me:13915: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:13916: \$? = $ac_status" >&5 + echo "$as_me:13919: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -15479,11 +15482,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:15482: $lt_compile\"" >&5) + (eval echo "\"\$as_me:15485: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:15486: \$? = $ac_status" >&5 + echo "$as_me:15489: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -15583,11 +15586,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:15586: $lt_compile\"" >&5) + (eval echo "\"\$as_me:15589: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:15590: \$? = $ac_status" >&5 + echo "$as_me:15593: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -17790,11 +17793,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:17793: $lt_compile\"" >&5) + (eval echo "\"\$as_me:17796: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:17797: \$? = $ac_status" >&5 + echo "$as_me:17800: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -18058,11 +18061,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:18061: $lt_compile\"" >&5) + (eval echo "\"\$as_me:18064: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:18065: \$? = $ac_status" >&5 + echo "$as_me:18068: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -18162,11 +18165,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:18165: $lt_compile\"" >&5) + (eval echo "\"\$as_me:18168: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:18169: \$? = $ac_status" >&5 + echo "$as_me:18172: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized diff --git a/libs/js/configure.ac b/libs/js/configure.ac index 4304430758..64f40581fb 100644 --- a/libs/js/configure.ac +++ b/libs/js/configure.ac @@ -41,12 +41,15 @@ AC_PROG_CC AC_CHECK_DEBUGGING AC_CHECK_VA_COPY +OLD_CFLAGS="$CFLAGS" +CFLAGS="" AC_CHECK_LIB(nsl, gethostname) if test ".`echo $LIBS | grep nsl`" = .; then AC_CHECK_LIB(nsl, gethostbyname) fi AC_CHECK_LIB(socket, accept) AC_CHECK_LIB(m, floor) +CFLAGS="$OLD_CFLAGS" AC_CHECK_MEMBERS([struct stat.st_birthtime, struct stat.st_birthtimensec],,, [#include ])