From a3c7cbfed365d77c78b4eceecefde6c3536ba85f Mon Sep 17 00:00:00 2001 From: Jim McDonough Date: Thu, 16 May 2002 19:59:25 +0000 Subject: 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) --- source3/configure.in | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'source3/configure.in') 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 +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 -- cgit