Changeset 3606 for trunk/configure.ac


Ignore:
Timestamp:
Oct 27, 2007, 9:29:41 PM (15 years ago)
Author:
charles
Message:

compatability with older C copmilers (ticket #422, patch by fizz)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/configure.ac

    r3536 r3606  
    3636AC_SEARCH_LIBS([socket], [socket net])
    3737AC_SEARCH_LIBS([gethostbyname], [nsl bind])
     38
     39dnl ----------------------------------------------------------------------------
     40dnl
     41dnl va_copy
     42
     43AC_MSG_CHECKING([how to copy va_list])
     44AC_TRY_LINK([#include <stdarg.h>], [va_list ap1, ap2; va_copy(ap1, ap2);],
     45    AC_MSG_RESULT([va_copy]),
     46        [ AH_TEMPLATE([va_copy], [define if va_copy is not available])
     47        AC_TRY_LINK([#include <stdarg.h>], [va_list ap1, ap2; __va_copy(ap1, ap2);],
     48        [ AC_DEFINE([va_copy], [__va_copy])
     49        AC_MSG_RESULT([__va_copy])],
     50        [ AC_DEFINE([va_copy(dest,src)], [memcpy(&dest,&src,sizeof(va_list))])
     51        AC_MSG_RESULT([memcpy])]
     52    )
     53])
     54
    3855
    3956dnl ----------------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.