aboutsummaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2008-12-15 17:43:59 +0000
committerfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2008-12-15 17:43:59 +0000
commit0b321028e4e0939ea8c4d39fa53bc34b19bc14c8 (patch)
tree492f084565e42c52b051a74dee2907d20cf5dde9 /configure
parentb9f2b5a4aa961a7389a42e56b74dae5f293bb2dd (diff)
Use autoconf logic to determine whether the system has timersub or not. Do not blindly assume Solaris does not.
(closes issue #13838) Reported by: ano git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@164343 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure64
1 files changed, 59 insertions, 5 deletions
diff --git a/configure b/configure
index fc40eb4ab..fbcc9cff5 100755
--- a/configure
+++ b/configure
@@ -1,5 +1,5 @@
#! /bin/sh
-# From configure.ac Revision: 159025 .
+# From configure.ac Revision: 159808 .
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.61 for asterisk 1.4.
#
@@ -14572,6 +14572,60 @@ fi
done
+{ echo "$as_me:$LINENO: checking for timersub in time.h" >&5
+echo $ECHO_N "checking for timersub in time.h... $ECHO_C" >&6; }
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <sys/time.h>
+int
+main ()
+{
+struct timeval *zombies; timersub(zombies, zombies, zombies);
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+ (eval "$ac_link") 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest$ac_exeext &&
+ $as_test_x conftest$ac_exeext; then
+ { echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_TIMERSUB 1
+_ACEOF
+
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+ conftest$ac_exeext conftest.$ac_ext
+
# some systems already have gethostbyname_r so we don't need to build ours in main/utils.c
{ echo "$as_me:$LINENO: checking for library containing gethostbyname_r" >&5
echo $ECHO_N "checking for library containing gethostbyname_r... $ECHO_C" >&6; }
@@ -15378,9 +15432,9 @@ if $(${CC} -Wdeclaration-after-statement -S -o /dev/null -xc /dev/null > /dev/nu
echo "${ECHO_T}yes" >&6; }
AST_DECLARATION_AFTER_STATEMENT=-Wdeclaration-after-statement
else
- { echo "$as_me:$LINENO: result: no" >&5
+ { echo "$as_me:$LINENO: result: no" >&5
echo "${ECHO_T}no" >&6; }
- AST_DECLARATION_AFTER_STATEMENT=
+ AST_DECLARATION_AFTER_STATEMENT=
fi
@@ -15404,9 +15458,9 @@ if $(${CC} -O2 -fno-strict-overflow -S -o /dev/null -xc /dev/null > /dev/null 2>
echo "${ECHO_T}yes" >&6; }
AST_NO_STRICT_OVERFLOW=-fno-strict-overflow
else
- { echo "$as_me:$LINENO: result: no" >&5
+ { echo "$as_me:$LINENO: result: no" >&5
echo "${ECHO_T}no" >&6; }
- AST_NO_STRICT_OVERFLOW=
+ AST_NO_STRICT_OVERFLOW=
fi