summaryrefslogtreecommitdiffstats
path: root/configure.in
diff options
context:
space:
mode:
authorJeremy T. Bouse <undrgrid@users.sourceforge.net>2003-03-12 17:11:20 (GMT)
committerJeremy T. Bouse <undrgrid@users.sourceforge.net>2003-03-12 17:11:20 (GMT)
commit48442b777389cfecb95f07b800d69dbac24130f0 (patch)
tree89503205708962a022c89c26fc0f5159ec3b9f62 /configure.in
parent46b0e78076a4c712f9c58b4f7804ba50b5895f46 (diff)
downloadmonitoring-plugins-48442b777389cfecb95f07b800d69dbac24130f0.tar.gz
Added autogen.sh script that rebuilds using autotools and runs configure
Modified configure.in to include some debug build option info at the end of the scripts execution. Can be removed by release time. Modified configure.in to include a --with-ipv6 option Default build is without IPv6 support now to enable you need to use the --with-ipv6 command line option to configure. Modified plugins/utils.* to use USE_IPV6 git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@410 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in51
1 files changed, 36 insertions, 15 deletions
diff --git a/configure.in b/configure.in
index 48e4506..529b7bb 100644
--- a/configure.in
+++ b/configure.in
@@ -300,6 +300,29 @@ AC_ARG_WITH(openssl,
300 [sets path to openssl installation]), 300 [sets path to openssl installation]),
301 OPENSSL=$withval,) 301 OPENSSL=$withval,)
302 302
303AC_ARG_WITH([ipv6],
304 ACX_HELP_STRING([--with-ipv6],
305 [enable IPv6 support (default=no)]),
306 ac_cv_sys_use_ipv6=$withval,
307 ac_cv_sys_use_ipv6=no)
308
309dnl Check for AF_INET6 support
310AC_CACHE_CHECK([for IPv6 support], ac_cv_sys_use_ipv6, [
311 AC_TRY_COMPILE([#include <netinet/in.h>],
312 [struct sockaddr_in6 sin6;
313 void *p;
314
315 sin6.sin6_family = AF_INET6;
316 sin6.sin6_port = 587;
317 p = &sin6.sin6_addr;],
318 [ac_cv_sys_use_ipv6=yes],
319 [ac_cv_sys_use_ipv6=no])
320 ])
321
322if test x"$ac_cv_sys_use_ipv6" != xno ; then
323 AC_DEFINE(USE_IPV6,1,[Enable IPv6 support])
324fi
325
303dnl ######################################################################### 326dnl #########################################################################
304dnl Check if Posix getaddrinfo() is available. It is also possible to use 327dnl Check if Posix getaddrinfo() is available. It is also possible to use
305dnl the version from the lwres library distributed with BIND. 328dnl the version from the lwres library distributed with BIND.
@@ -398,21 +421,6 @@ if test x"$enable_emulate_getaddrinfo" != xno ; then
398 fi 421 fi
399 LIBOBJS="$LIBOBJS gethostbyname.o" 422 LIBOBJS="$LIBOBJS gethostbyname.o"
400 423
401 AC_CACHE_CHECK([for IPv6 support], acx_cv_sys_use_ipv6, [
402 AC_TRY_COMPILE([
403# include <netinet/in.h>
404 ], [
405 struct sockaddr_in6 sin6;
406 void *p;
407
408 sin6.sin6_family = AF_INET6;
409 sin6.sin6_port = 587;
410 p = &sin6.sin6_addr;
411 ], [acx_cv_sys_use_ipv6=yes], [acx_cv_sys_use_ipv6=no])
412 ])
413 if test x"$acx_cv_sys_use_ipv6" != xno ; then
414 AC_DEFINE(USE_IPV6,1,[Enable IPv6 support])
415 fi
416fi 424fi
417 425
418AC_CHECK_HEADERS(krb5.h,FOUNDINCLUDE=yes,FOUNDINCLUDE=no) 426AC_CHECK_HEADERS(krb5.h,FOUNDINCLUDE=yes,FOUNDINCLUDE=no)
@@ -1047,6 +1055,7 @@ AC_ARG_WITH(ping6_command,
1047 [sets syntax for ICMPv6 ping]), 1055 [sets syntax for ICMPv6 ping]),
1048 ac_cv_ping6_command=$withval,) 1056 ac_cv_ping6_command=$withval,)
1049 1057
1058if test x"$ac_cv_sys_use_ipv6" != xno ; then
1050AC_MSG_CHECKING(for ICMPv6 ping syntax) 1059AC_MSG_CHECKING(for ICMPv6 ping syntax)
1051ac_cv_ping6_packets_first=no 1060ac_cv_ping6_packets_first=no
1052if test -n "$ac_cv_ping6_command" 1061if test -n "$ac_cv_ping6_command"
@@ -1196,6 +1205,7 @@ if test "x$ac_cv_ping6_packets_first" != "xno"; then
1196 AC_DEFINE(PING6_PACKETS_FIRST,1, 1205 AC_DEFINE(PING6_PACKETS_FIRST,1,
1197 [Define if packet count must precede host]) 1206 [Define if packet count must precede host])
1198fi 1207fi
1208fi
1199 1209
1200AC_PATH_PROG(PATH_TO_NSLOOKUP,nslookup) 1210AC_PATH_PROG(PATH_TO_NSLOOKUP,nslookup)
1201 1211
@@ -1453,3 +1463,14 @@ AC_SUBST(DEPLIBS)
1453AC_DEFINE_UNQUOTED(PACKAGE_VERSION,"${VERSION}",[package version]) 1463AC_DEFINE_UNQUOTED(PACKAGE_VERSION,"${VERSION}",[package version])
1454 1464
1455AC_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) 1465AC_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)
1466
1467ACX_FEATURE([with],[cgiurl],[$cgiurl])
1468ACX_FEATURE([with],[nagios-user],[$nagios_usr])
1469ACX_FEATURE([with],[nagios-group],[$nagios_grp])
1470ACX_FEATURE([with],[trusted-path],[$trusted_path])
1471ACX_FEATURE([with],[df-command],[$ac_cv_df_command])
1472ACX_FEATURE([with],[ping-command],[$ac_cv_ping_command])
1473ACX_FEATURE([with],[ping6-command],[$ac_cv_ping6_command])
1474ACX_FEATURE([with],[lwres])
1475ACX_FEATURE([with],[ipv6],[$ac_cv_sys_use_ipv6])
1476ACX_FEATURE([enable],[emulate-getaddrinfo])