summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorrob rob@31f1291d-b8d6-0310-a050-a5561fc1590b <rob rob@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2006-01-25 20:44:50 +0000
committerrob rob@31f1291d-b8d6-0310-a050-a5561fc1590b <rob rob@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2006-01-25 20:44:50 +0000
commit033ce652559ac342a94bdf9edbabe77ed1e81369 (patch)
treec8c662808401929e4fafcefe24b835b558cf3edf /configure
parent9435ddae0c408d39c623f6bdc7650c2bf0981c0c (diff)
Added va_copy macro, along with a autoconf test.
git-svn-id: svn://svn.anope.org/anope/trunk@959 31f1291d-b8d6-0310-a050-a5561fc1590b git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@686 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure69
1 files changed, 69 insertions, 0 deletions
diff --git a/configure b/configure
index c91ac99ed..7216be0aa 100755
--- a/configure
+++ b/configure
@@ -1306,6 +1306,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
if test $# = 0; then
echo "You might want to run ./Config or provide some parameters to this script."
echo "./configure --help for information about this script"
@@ -2740,6 +2741,74 @@ if test $ac_cv_lib_bsd_revoke = yes; then
fi
x="0";
+
+
+
+echo "$as_me:$LINENO: checking whether va_list assignments need array notation" >&5
+echo $ECHO_N "checking whether va_list assignments need array notation... $ECHO_C" >&6
+if test "${ac_cv_valistisarray+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test "$cross_compiling" = yes; then
+ ac_cv_valistisarray=false
+else
+ cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <stdlib.h>
+ #include <stdarg.h>
+ void foo(int i, ...) {
+ va_list ap1, ap2;
+ va_start(ap1, i);
+ ap2 = ap1;
+ if (va_arg(ap2, int) != 123 || va_arg(ap1, int) != 123) { exit(1); }
+ va_end(ap1); va_end(ap2);
+ }
+ int main()
+ { foo(0, 123); return(0); }
+_ACEOF
+rm -f conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_valistisarray=false
+else
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+ac_cv_valistisarray=true
+fi
+rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
+fi
+
+
+if test "$ac_cv_valistisarray" = true ; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_VA_LIST_AS_ARRAY 1
+_ACEOF
+
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+
DIS_MYSQL=" MySql: No"
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'