diff options
Diffstat (limited to 'configure.ac')
-rwxr-xr-x | configure.ac | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index 6294eb06..4cad8282 100755 --- a/configure.ac +++ b/configure.ac @@ -494,6 +494,31 @@ AC_SUBST(RT_METHOD) AC_SUBST(KERNEL_METHOD) AC_SUBST(OTHER_METHOD) +dnl ------------------------------------ +dnl check for broken CMSG_FIRSTHDR macro +dnl ------------------------------------ +AC_TRY_RUN([ +#ifdef SUNOS_5 +#define _XPG4_2 +#define __EXTENSIONS__ +#endif +#include <stdlib.h> +#include <sys/types.h> +#include <sys/socket.h> + +main() +{ + struct msghdr msg; + char buf[4]; + + msg.msg_control = buf; + msg.msg_controllen = 0; + + if (CMSG_FIRSTHDR(&msg) != NULL) + exit(0); + exit (1); +}],[AC_DEFINE(HAVE_BROKEN_CMSG_FIRSTHDR,,Broken CMSG_FIRSTHDR)]) + dnl ------------------------------ dnl check kernel route read method dnl ------------------------------ |