Mercurial > pidgin
comparison configure.ac @ 25263:b9f7a8ca1369
Apparently our use of va_list arguments in the perl signal callbacks doesn't
work on x86_64 (and other architectures where a va_list is not a pointer but
an array).
Pull an autoconf macro from Glib svn to check whether va_lists are arrays and
switch how we use them on that.
I'm not at all sure this is a complete fix but it seems to fix the issue as
currently reported.
Fixes #7404
author | Etan Reisner <pidgin@unreliablesource.net> |
---|---|
date | Tue, 06 Jan 2009 06:29:44 +0000 |
parents | 60c07b55a24a |
children | b3d4f47f015c c324304cc827 |
comparison
equal
deleted
inserted
replaced
25262:df6d3c3574ce | 25263:b9f7a8ca1369 |
---|---|
2281 struct tm tm; | 2281 struct tm tm; |
2282 tm.tm_gmtoff = 1; | 2282 tm.tm_gmtoff = 1; |
2283 ], ac_cv_struct_tm_gmtoff=yes, ac_cv_struct_tm_gmtoff=no)) | 2283 ], ac_cv_struct_tm_gmtoff=yes, ac_cv_struct_tm_gmtoff=no)) |
2284 if test $ac_cv_struct_tm_gmtoff = yes; then | 2284 if test $ac_cv_struct_tm_gmtoff = yes; then |
2285 AC_DEFINE(HAVE_TM_GMTOFF, 1, [Define if you have a tm_gmtoff member in struct tm]) | 2285 AC_DEFINE(HAVE_TM_GMTOFF, 1, [Define if you have a tm_gmtoff member in struct tm]) |
2286 fi | |
2287 | |
2288 AC_CACHE_CHECK([whether va_lists can be copied by value], ac_cv_va_val_copy,[ | |
2289 AC_TRY_RUN([#include <stdarg.h> | |
2290 #include <stdlib.h> | |
2291 void f (int i, ...) { | |
2292 va_list args1, args2; | |
2293 va_start (args1, i); | |
2294 args2 = args1; | |
2295 if (va_arg (args2, int) != 42 || va_arg (args1, int) != 42) | |
2296 exit (1); | |
2297 va_end (args1); va_end (args2); | |
2298 } | |
2299 int main() { | |
2300 f (0, 42); | |
2301 return 0; | |
2302 }], | |
2303 [ac_cv_va_val_copy=yes], | |
2304 [ac_cv_va_val_copy=no], | |
2305 [ac_cv_va_val_copy=yes]) | |
2306 ]) | |
2307 | |
2308 if test "x$ac_cv_va_val_copy" = "xno"; then | |
2309 AC_DEFINE(VA_COPY_AS_ARRAY, 1, ['va_lists' cannot be copied as values]) | |
2286 fi | 2310 fi |
2287 | 2311 |
2288 dnl ####################################################################### | 2312 dnl ####################################################################### |
2289 dnl # Check for check | 2313 dnl # Check for check |
2290 dnl ####################################################################### | 2314 dnl ####################################################################### |