diff options
| author | certus certus@31f1291d-b8d6-0310-a050-a5561fc1590b <certus certus@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864> | 2006-01-23 19:43:56 +0000 |
|---|---|---|
| committer | certus certus@31f1291d-b8d6-0310-a050-a5561fc1590b <certus certus@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864> | 2006-01-23 19:43:56 +0000 |
| commit | 0dc104f20dcfa3dbdf301949a4c01d2f38c02687 (patch) | |
| tree | 588296fc3c84d9cb01f61eabe5910dd04e4539d7 /configure.in | |
| parent | d86dddd6e723c223de8b0341a083d520f7a92c18 (diff) | |
BUILD : 1.7.13 (956) BUGS : NOTES : applied patch provided by trystan
git-svn-id: svn://svn.anope.org/anope/trunk@956 31f1291d-b8d6-0310-a050-a5561fc1590b
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@683 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'configure.in')
| -rw-r--r-- | configure.in | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/configure.in b/configure.in index f170d9317..1e11b76d9 100644 --- a/configure.in +++ b/configure.in @@ -220,6 +220,34 @@ AC_ARG_WITH(encryption, [ --with-encryption Use md5 database encryption], [ AC_DEFINE_UNQUOTED(ENCRYPT_MD5,,"Use md5") ]) +dnl Does this platform require array notation to assign to a va_list? +dnl If cross-compiling, we assume va_list is "normal". If this breaks +dnl you, set ac_cv_valistisarray=true and maybe define HAVE_VA_LIST_AS_ARRAY +dnl also just to be sure. +AC_MSG_CHECKING(whether va_list assignments need array notation) +AC_CACHE_VAL(ac_cv_valistisarray, + [AC_TRY_RUN([#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); }], + [ac_cv_valistisarray=false], + [ac_cv_valistisarray=true], + [ac_cv_valistisarray=false])]) + +if test "$ac_cv_valistisarray" = true ; then + AC_DEFINE(HAVE_VA_LIST_AS_ARRAY) + AC_MSG_RESULT(yes) +else + AC_MSG_RESULT(no) +fi + AC_CONFIG_FILES( \ Makefile \ src/bin/anoperc \ |
