diff options
author | Stefan Metzmacher <metze@samba.org> | 2006-10-11 05:18:20 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:15:23 -0500 |
commit | 9b5c5bc3f3912776af6a8c9b13a9cb8dd2eff8f8 (patch) | |
tree | 89ef839e1d6836e80ac32c9cc488e3d1f587784d /source | |
parent | 88fa5ac7347cbae92abe17da8d3af00e85110c43 (diff) | |
download | samba-9b5c5bc3f3912776af6a8c9b13a9cb8dd2eff8f8.tar.gz samba-9b5c5bc3f3912776af6a8c9b13a9cb8dd2eff8f8.tar.xz samba-9b5c5bc3f3912776af6a8c9b13a9cb8dd2eff8f8.zip |
r19232: merge from samba4:
- machine/sys/getppdp.h workaround for HPUX 11.23
- more verbose check for net/if.h
metze
Diffstat (limited to 'source')
-rw-r--r-- | source/lib/replace/libreplace.m4 | 31 | ||||
-rw-r--r-- | source/lib/replace/libreplace_cc.m4 | 4 |
2 files changed, 19 insertions, 16 deletions
diff --git a/source/lib/replace/libreplace.m4 b/source/lib/replace/libreplace.m4 index 804f998b9e5..662993cb79b 100644 --- a/source/lib/replace/libreplace.m4 +++ b/source/lib/replace/libreplace.m4 @@ -102,22 +102,21 @@ AC_CHECK_HEADERS(sys/sockio.h sys/un.h) dnl we need to check that net/if.h really can be used, to cope with hpux dnl where including it always fails -AC_TRY_COMPILE([ - #include <stdio.h> - #if STDC_HEADERS - # include <stdlib.h> - # include <stddef.h> - #else - # if HAVE_STDLIB_H - # include <stdlib.h> - # endif - #endif - #if HAVE_SYS_SOCKET_H - # include <sys/socket.h> - #endif], - [#include <net/if.h>], - AC_DEFINE(HAVE_NET_IF_H, 1, usability of net/if.h)) - +AC_CACHE_CHECK([for usable net/if.h],libreplace_cv_USABLE_NET_IF_H,[ + AC_COMPILE_IFELSE([ + AC_INCLUDES_DEFAULT + #if HAVE_SYS_SOCKET_H + # include <sys/socket.h> + #endif + #include <net/if.h> + int main(void) {return 0;}], + [libreplace_cv_USABLE_NET_IF_H=yes], + [libreplace_cv_USABLE_NET_IF_H=no] + ) +]) +if test x"$libreplace_cv_USABLE_NET_IF_H" = x"yes";then + AC_DEFINE(HAVE_NET_IF_H, 1, usability of net/if.h) +fi AC_CACHE_CHECK([for broken inet_ntoa],samba_cv_REPLACE_INET_NTOA,[ AC_TRY_RUN([ diff --git a/source/lib/replace/libreplace_cc.m4 b/source/lib/replace/libreplace_cc.m4 index 77bb5a0598c..b8b74036e53 100644 --- a/source/lib/replace/libreplace_cc.m4 +++ b/source/lib/replace/libreplace_cc.m4 @@ -64,6 +64,10 @@ case "$host_os" in AC_MSG_WARN([Enabling HPUX 11.11 header bug workaround]) CFLAGS="$CFLAGS -D_LARGEFILE64_SUPPORT -D__LP64__ -DO_LARGEFILE=04000" fi + if test "`uname -r`" = "B.11.23"; then + AC_MSG_WARN([Enabling HPUX 11.23 machine/sys/getppdp.h bug workaround]) + CFLAGS="$CFLAGS -D_MACHINE_SYS_GETPPDP_INCLUDED" + fi ;; *aix*) AC_DEFINE(BROKEN_STRNDUP, 1, [Whether strndup is broken]) |