diff options
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 51 |
1 files changed, 36 insertions, 15 deletions
diff --git a/configure.in b/configure.in index 48e45067..529b7bbc 100644 --- a/configure.in +++ b/configure.in @@ -300,6 +300,29 @@ AC_ARG_WITH(openssl, [sets path to openssl installation]), OPENSSL=$withval,) +AC_ARG_WITH([ipv6], + ACX_HELP_STRING([--with-ipv6], + [enable IPv6 support (default=no)]), + ac_cv_sys_use_ipv6=$withval, + ac_cv_sys_use_ipv6=no) + +dnl Check for AF_INET6 support +AC_CACHE_CHECK([for IPv6 support], ac_cv_sys_use_ipv6, [ + AC_TRY_COMPILE([#include <netinet/in.h>], + [struct sockaddr_in6 sin6; + void *p; + + sin6.sin6_family = AF_INET6; + sin6.sin6_port = 587; + p = &sin6.sin6_addr;], + [ac_cv_sys_use_ipv6=yes], + [ac_cv_sys_use_ipv6=no]) + ]) + +if test x"$ac_cv_sys_use_ipv6" != xno ; then + AC_DEFINE(USE_IPV6,1,[Enable IPv6 support]) +fi + dnl ######################################################################### dnl Check if Posix getaddrinfo() is available. It is also possible to use dnl the version from the lwres library distributed with BIND. @@ -398,21 +421,6 @@ if test x"$enable_emulate_getaddrinfo" != xno ; then fi LIBOBJS="$LIBOBJS gethostbyname.o" - AC_CACHE_CHECK([for IPv6 support], acx_cv_sys_use_ipv6, [ - AC_TRY_COMPILE([ -# include <netinet/in.h> - ], [ - struct sockaddr_in6 sin6; - void *p; - - sin6.sin6_family = AF_INET6; - sin6.sin6_port = 587; - p = &sin6.sin6_addr; - ], [acx_cv_sys_use_ipv6=yes], [acx_cv_sys_use_ipv6=no]) - ]) - if test x"$acx_cv_sys_use_ipv6" != xno ; then - AC_DEFINE(USE_IPV6,1,[Enable IPv6 support]) - fi fi AC_CHECK_HEADERS(krb5.h,FOUNDINCLUDE=yes,FOUNDINCLUDE=no) @@ -1047,6 +1055,7 @@ AC_ARG_WITH(ping6_command, [sets syntax for ICMPv6 ping]), ac_cv_ping6_command=$withval,) +if test x"$ac_cv_sys_use_ipv6" != xno ; then AC_MSG_CHECKING(for ICMPv6 ping syntax) ac_cv_ping6_packets_first=no if test -n "$ac_cv_ping6_command" @@ -1196,6 +1205,7 @@ if test "x$ac_cv_ping6_packets_first" != "xno"; then AC_DEFINE(PING6_PACKETS_FIRST,1, [Define if packet count must precede host]) fi +fi AC_PATH_PROG(PATH_TO_NSLOOKUP,nslookup) @@ -1453,3 +1463,14 @@ AC_SUBST(DEPLIBS) AC_DEFINE_UNQUOTED(PACKAGE_VERSION,"${VERSION}",[package version]) AC_OUTPUT(Makefile subst lib/Makefile plugins/Makefile plugins-scripts/Makefile plugins-scripts/subst plugins-scripts/utils.pm plugins-scripts/utils.sh command.cfg test.pl,echo timestamp > plugins/stamp-h1;echo timestamp > plugins/stamp-h2;echo timestamp > plugins/stamp-h3;echo timestamp > plugins/stamp-h4;echo timestamp > plugins/stamp-h5;echo timestamp > plugins/stamp-h6;PATH=.:..:$PATH subst.sh command.cfg) + +ACX_FEATURE([with],[cgiurl],[$cgiurl]) +ACX_FEATURE([with],[nagios-user],[$nagios_usr]) +ACX_FEATURE([with],[nagios-group],[$nagios_grp]) +ACX_FEATURE([with],[trusted-path],[$trusted_path]) +ACX_FEATURE([with],[df-command],[$ac_cv_df_command]) +ACX_FEATURE([with],[ping-command],[$ac_cv_ping_command]) +ACX_FEATURE([with],[ping6-command],[$ac_cv_ping6_command]) +ACX_FEATURE([with],[lwres]) +ACX_FEATURE([with],[ipv6],[$ac_cv_sys_use_ipv6]) +ACX_FEATURE([enable],[emulate-getaddrinfo]) |