summaryrefslogtreecommitdiff
path: root/source3/configure.in
diff options
context:
space:
mode:
authorJim McDonough <jmcd@samba.org>2002-05-16 19:59:25 +0000
committerJim McDonough <jmcd@samba.org>2002-05-16 19:59:25 +0000
commita3c7cbfed365d77c78b4eceecefde6c3536ba85f (patch)
tree575bc758d81283527c2d7f64f5411d9ec3fa53a9 /source3/configure.in
parent6df90d3f2c7129bab11f508306cd5876a18f4989 (diff)
downloadsamba-a3c7cbfed365d77c78b4eceecefde6c3536ba85f.tar.gz
samba-a3c7cbfed365d77c78b4eceecefde6c3536ba85f.tar.bz2
samba-a3c7cbfed365d77c78b4eceecefde6c3536ba85f.zip
Add configure support for __va_copy, which is required on Linux/390 systems
when assigning on va_list to another, or when passing a va_list as an argument to a function. Not using it causes segv's and other unpredictable results. We need to check all over the place for this... (This used to be commit 331132678c2e25e5f220de34968f6b16f4fbbc97)
Diffstat (limited to 'source3/configure.in')
-rw-r--r--source3/configure.in8
1 files changed, 8 insertions, 0 deletions
diff --git a/source3/configure.in b/source3/configure.in
index e01b9cb392..a5460b70de 100644
--- a/source3/configure.in
+++ b/source3/configure.in
@@ -1173,6 +1173,14 @@ if test x"$samba_cv_HAVE_GETTIMEOFDAY_TZ" = x"yes"; then
AC_DEFINE(HAVE_GETTIMEOFDAY_TZ)
fi
+AC_CACHE_CHECK([for __va_copy],samba_cv_HAVE_VA_COPY,[
+AC_TRY_COMPILE([#include <stdarg.h>
+va_list ap1,ap2;], [__va_copy(ap1,ap2);],
+samba_cv_HAVE_VA_COPY=yes,samba_cv_HAVE_VA_COPY=no)])
+if test x"$samba_cv_HAVE_VA_COPY" = x"yes"; then
+ AC_DEFINE(HAVE_VA_COPY)
+fi
+
AC_CACHE_CHECK([for C99 vsnprintf],samba_cv_HAVE_C99_VSNPRINTF,[
AC_TRY_RUN([
#include <sys/types.h>