diff options
author | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2011-02-24 15:46:21 +0000 |
---|---|---|
committer | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2011-02-24 15:46:21 +0000 |
commit | 5906c072da69c084a3286e152aa64c0448e71865 (patch) | |
tree | 0166a34ad34270c6df76cae9a2906e48e91dcda1 | |
parent | 07a54bb2f18adc2121e7b55689e5d4e54331d65d (diff) |
Modernize checks for ISO/GNU varargs
Part of a patch by Javier Jardón.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=32245
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
-rw-r--r-- | configure.ac | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac index aea975a6..86e486ab 100644 --- a/configure.ac +++ b/configure.ac @@ -629,19 +629,23 @@ AC_CHECK_DECLS([MSG_NOSIGNAL], [], [], [[ #include <sys/socket.h> ]]) dnl check for flavours of varargs macros (test from GLib) AC_MSG_CHECKING(for ISO C99 varargs macros in C) -AC_TRY_COMPILE([],[ +AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ int a(int p1, int p2, int p3); #define call_a(...) a(1,__VA_ARGS__) call_a(2,3); -],dbus_have_iso_c_varargs=yes,dbus_have_iso_c_varargs=no) +]])], +[dbus_have_iso_c_varargs=yes], +[dbus_have_iso_c_varargs=no]) AC_MSG_RESULT($dbus_have_iso_c_varargs) AC_MSG_CHECKING(for GNUC varargs macros) -AC_TRY_COMPILE([],[ +AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ int a(int p1, int p2, int p3); #define call_a(params...) a(1,params) call_a(2,3); -],dbus_have_gnuc_varargs=yes,dbus_have_gnuc_varargs=no) +]])], +[dbus_have_gnuc_varargs=yes], +[dbus_have_gnuc_varargs=no]) AC_MSG_RESULT($dbus_have_gnuc_varargs) dnl Output varargs tests |