diff options
| author | tgoodwin <tgoodwin> | 1998-10-28 14:15:21 +0000 |
|---|---|---|
| committer | Toby Goodwin <toby@paccrat.org> | 2015-05-16 21:23:12 +0100 |
| commit | f034ca39df7f6f513d0d4d4f479194592ac48645 (patch) | |
| tree | 4ab1c68a27cf65c5213df77c0a2e51f59a66c498 /acinclude.m4 | |
| parent | d535c86b0f886e1c4cf0ae73048bf4bdba6d0813 (diff) | |
use va_copy() where it exists
Diffstat (limited to 'acinclude.m4')
| -rw-r--r-- | acinclude.m4 | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/acinclude.m4 b/acinclude.m4 index 60ec318..2ac2cab 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -34,3 +34,15 @@ int main(void) { yes) AC_DEFINE(SETPGRP_VOID) ;; esac ]) + +dnl Check for va_copy() in <stdarg.h>. This is new in C 9x. +AC_DEFUN(RC_HAVE_VA_COPY, [ + AC_CACHE_CHECK(for va_copy(), rc_cv_have_va_copy, AC_EGREP_CPP(yes, [ +#ifdef va_copy +yes +#endif +], rc_cv_have_va_copy=yes, rc_cv_have_va_copy=no)) + case "$rc_cv_have_va_copy" in + yes) AC_DEFINE(HAVE_VA_COPY) ;; + esac +]) |