diff options
-rw-r--r-- | configure.in | 209 | ||||
-rw-r--r-- | plugins-scripts/subst.in | 4 |
2 files changed, 106 insertions, 107 deletions
diff --git a/configure.in b/configure.in index 21c55e6b..9d3c2edd 100644 --- a/configure.in +++ b/configure.in | |||
@@ -87,32 +87,32 @@ dnl CGIURL has changed for Nagios with 1.0 beta | |||
87 | AC_ARG_WITH(cgiurl, | 87 | AC_ARG_WITH(cgiurl, |
88 | ACX_HELP_STRING([--with-cgiurl=DIR], | 88 | ACX_HELP_STRING([--with-cgiurl=DIR], |
89 | [sets URL for cgi programs]), | 89 | [sets URL for cgi programs]), |
90 | cgiurl=$withval, | 90 | with_cgiurl=$withval, |
91 | cgiurl=/nagios/cgi-bin) | 91 | with_cgiurl=/nagios/cgi-bin) |
92 | CGIURL="$cgiurl" | 92 | CGIURL="$with_cgiurl" |
93 | AC_DEFINE_UNQUOTED(CGIURL,"$CGIURL",[URL of CGI programs]) | 93 | AC_DEFINE_UNQUOTED(CGIURL,"$CGIURL",[URL of CGI programs]) |
94 | 94 | ||
95 | AC_ARG_WITH(nagios_user, | 95 | AC_ARG_WITH(nagios_user, |
96 | ACX_HELP_STRING([--with-nagios-user=USER], | 96 | ACX_HELP_STRING([--with-nagios-user=USER], |
97 | [set user name to run nagios]), | 97 | [set user name to run nagios]), |
98 | nagios_usr=$withval, | 98 | with_nagios_user=$withval, |
99 | nagios_usr=nagios) | 99 | with_nagios_user=nagios) |
100 | AC_ARG_WITH(nagios_group, | 100 | AC_ARG_WITH(nagios_group, |
101 | ACX_HELP_STRING([--with-nagios-group=GROUP], | 101 | ACX_HELP_STRING([--with-nagios-group=GROUP], |
102 | [set group name to run nagios]), | 102 | [set group name to run nagios]), |
103 | nagios_grp=$withval, | 103 | with_nagios_group=$withval, |
104 | nagios_grp=nagios) | 104 | with_nagios_group=nagios) |
105 | AC_SUBST(nagios_usr) | 105 | AC_SUBST(with_nagios_user) |
106 | AC_SUBST(nagios_grp) | 106 | AC_SUBST(with_nagios_group) |
107 | INSTALL_OPTS="-o $nagios_usr -g $nagios_grp" | 107 | INSTALL_OPTS="-o $with_nagios_user -g $with_nagios_group" |
108 | AC_SUBST(INSTALL_OPTS) | 108 | AC_SUBST(INSTALL_OPTS) |
109 | 109 | ||
110 | AC_ARG_WITH(trusted_path, | 110 | AC_ARG_WITH(trusted_path, |
111 | ACX_HELP_STRING([--with-trusted-path=PATH], | 111 | ACX_HELP_STRING([--with-trusted-path=PATH], |
112 | [sets trusted path for executables called by scripts (default=/bin:/sbin:/usr/bin:/usr/sbin)]), | 112 | [sets trusted path for executables called by scripts (default=/bin:/sbin:/usr/bin:/usr/sbin)]), |
113 | trusted_path=$withval, | 113 | with_trusted_path=$withval, |
114 | trusted_path=/bin:/sbin:/usr/bin:/usr/sbin) | 114 | with_trusted_path=/bin:/sbin:/usr/bin:/usr/sbin) |
115 | AC_SUBST(trusted_path) | 115 | AC_SUBST(with_trusted_path) |
116 | 116 | ||
117 | EXTRAS= | 117 | EXTRAS= |
118 | dnl PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/etc:/usr/local/bin:/usr/local/sbin:$PATH | 118 | dnl PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/etc:/usr/local/bin:/usr/local/sbin:$PATH |
@@ -304,22 +304,23 @@ AC_ARG_WITH([ipv6], | |||
304 | ACX_HELP_STRING([--with-ipv6], | 304 | ACX_HELP_STRING([--with-ipv6], |
305 | [enable IPv6 support (default=no)]), | 305 | [enable IPv6 support (default=no)]), |
306 | , | 306 | , |
307 | ac_cv_sys_use_ipv6=no) | 307 | with_ipv6=no) |
308 | 308 | ||
309 | dnl Check for AF_INET6 support | 309 | dnl Check for AF_INET6 support |
310 | AC_CACHE_CHECK([for IPv6 support], ac_cv_sys_use_ipv6, [ | 310 | AC_CACHE_CHECK([for IPv6 support], with_ipv6, [ |
311 | AC_TRY_COMPILE([#include <netinet/in.h>], | 311 | AC_TRY_COMPILE([#include <netinet/in.h> |
312 | #include <sys/socket.h>], | ||
312 | [struct sockaddr_in6 sin6; | 313 | [struct sockaddr_in6 sin6; |
313 | void *p; | 314 | void *p; |
314 | 315 | ||
315 | sin6.sin6_family = AF_INET6; | 316 | sin6.sin6_family = AF_INET6; |
316 | sin6.sin6_port = 587; | 317 | sin6.sin6_port = 587; |
317 | p = &sin6.sin6_addr;], | 318 | p = &sin6.sin6_addr;], |
318 | [ac_cv_sys_use_ipv6=yes], | 319 | [with_ipv6=yes], |
319 | [ac_cv_sys_use_ipv6=no]) | 320 | [with_ipv6=no]) |
320 | ]) | 321 | ]) |
321 | 322 | ||
322 | if test x"$ac_cv_sys_use_ipv6" != xno ; then | 323 | if test x"$with_ipv6" != xno ; then |
323 | AC_DEFINE(USE_IPV6,1,[Enable IPv6 support]) | 324 | AC_DEFINE(USE_IPV6,1,[Enable IPv6 support]) |
324 | fi | 325 | fi |
325 | 326 | ||
@@ -924,38 +925,38 @@ AC_PATH_PROG(PATH_TO_BDF,bdf) | |||
924 | AC_ARG_WITH(df_command, | 925 | AC_ARG_WITH(df_command, |
925 | ACX_HELP_STRING([--with-df-command=SYNTAX], | 926 | ACX_HELP_STRING([--with-df-command=SYNTAX], |
926 | [sets syntax for df]), | 927 | [sets syntax for df]), |
927 | ac_cv_df_command=$withval,) | 928 | with_df_command=$withval,) |
928 | 929 | ||
929 | AC_MSG_CHECKING(for df syntax) | 930 | AC_MSG_CHECKING(for df syntax) |
930 | if test -n "$ac_cv_df_command" | 931 | if test -n "$with_df_command" |
931 | then | 932 | then |
932 | AC_MSG_RESULT([$ac_cv_df_command]) | 933 | AC_MSG_RESULT([$with_df_command]) |
933 | 934 | ||
934 | elif df -Pk 2>/dev/null | egrep -i ["^(/dev/|[a-zA-Z]:)[a-z0-9/\\]+ +[0-9]+ +[0-9]+ +[0-9]+ +[0-9]+% +/[a-z0-9/\\]*"] >/dev/null | 935 | elif df -Pk 2>/dev/null | egrep -i ["^(/dev/|[a-zA-Z]:)[a-z0-9/\\]+ +[0-9]+ +[0-9]+ +[0-9]+ +[0-9]+% +/[a-z0-9/\\]*"] >/dev/null |
935 | then | 936 | then |
936 | ac_cv_df_command="$PATH_TO_DF -Pk" | 937 | with_df_command="$PATH_TO_DF -Pk" |
937 | AC_MSG_RESULT([$ac_cv_df_command]) | 938 | AC_MSG_RESULT([$with_df_command]) |
938 | 939 | ||
939 | elif df -k 2>/dev/null | egrep -i ["^/dev/[a-z0-9/]+ +[0-9]+ +[0-9]+ +[0-9]+ +[0-9]+% +/[a-z0-9/]*"] >/dev/null | 940 | elif df -k 2>/dev/null | egrep -i ["^/dev/[a-z0-9/]+ +[0-9]+ +[0-9]+ +[0-9]+ +[0-9]+% +/[a-z0-9/]*"] >/dev/null |
940 | then | 941 | then |
941 | ac_cv_df_command="$PATH_TO_DF -k" | 942 | with_df_command="$PATH_TO_DF -k" |
942 | AC_MSG_RESULT([$ac_cv_df_command]) | 943 | AC_MSG_RESULT([$with_df_command]) |
943 | 944 | ||
944 | elif df 2>/dev/null | egrep -i ["^/dev/[a-z0-9/]+ +[0-9]+ +[0-9]+ +[0-9]+ +[0-9]+% +/[a-z0-9/]*"] >/dev/null | 945 | elif df 2>/dev/null | egrep -i ["^/dev/[a-z0-9/]+ +[0-9]+ +[0-9]+ +[0-9]+ +[0-9]+% +/[a-z0-9/]*"] >/dev/null |
945 | then | 946 | then |
946 | ac_cv_df_command="$PATH_TO_DF" | 947 | with_df_command="$PATH_TO_DF" |
947 | AC_MSG_RESULT([$ac_cv_df_command]) | 948 | AC_MSG_RESULT([$with_df_command]) |
948 | 949 | ||
949 | elif bdf 2>/dev/null | egrep -i ["^/dev/[a-z0-9/]+ +[0-9]+ +[0-9]+ +[0-9]+ +[0-9]+% +/[a-z0-9/]*"] >/dev/null | 950 | elif bdf 2>/dev/null | egrep -i ["^/dev/[a-z0-9/]+ +[0-9]+ +[0-9]+ +[0-9]+ +[0-9]+% +/[a-z0-9/]*"] >/dev/null |
950 | then | 951 | then |
951 | ac_cv_df_command="$PATH_TO_BDF" | 952 | with_df_command="$PATH_TO_BDF" |
952 | AC_MSG_RESULT([$ac_cv_df_command]) | 953 | AC_MSG_RESULT([$with_df_command]) |
953 | 954 | ||
954 | else | 955 | else |
955 | AC_MSG_WARN([unable to find usable df syntax]) | 956 | AC_MSG_WARN([unable to find usable df syntax]) |
956 | fi | 957 | fi |
957 | 958 | ||
958 | AC_DEFINE_UNQUOTED(DF_COMMAND,"$ac_cv_df_command",[path and args for df command]) | 959 | AC_DEFINE_UNQUOTED(DF_COMMAND,"$with_df_command",[path and args for df command]) |
959 | 960 | ||
960 | AC_PATH_PROG(PATH_TO_PING,ping) | 961 | AC_PATH_PROG(PATH_TO_PING,ping) |
961 | AC_PATH_PROG(PATH_TO_PING6,ping6) | 962 | AC_PATH_PROG(PATH_TO_PING6,ping6) |
@@ -963,85 +964,83 @@ AC_PATH_PROG(PATH_TO_PING6,ping6) | |||
963 | AC_ARG_WITH(ping_command, | 964 | AC_ARG_WITH(ping_command, |
964 | ACX_HELP_STRING([--with-ping-command=SYNTAX], | 965 | ACX_HELP_STRING([--with-ping-command=SYNTAX], |
965 | [sets syntax for ICMP ping]), | 966 | [sets syntax for ICMP ping]), |
966 | ac_cv_ping_command=$withval,) | 967 | with_ping_command=$withval,) |
967 | 968 | ||
968 | AC_MSG_CHECKING(for ICMP ping syntax) | 969 | AC_MSG_CHECKING(for ICMP ping syntax) |
969 | ac_cv_ping_packets_first=no | 970 | ac_cv_ping_packets_first=no |
970 | if test -n "$ac_cv_ping_command" | 971 | if test -n "$with_ping_command" |
971 | then | 972 | then |
972 | AC_MSG_RESULT([(command-line) $ac_cv_ping_command]) | 973 | AC_MSG_RESULT([(command-line) $with_ping_command]) |
973 | if test -n "$ac_cv_ping_packets_first" | 974 | if test -n "$ac_cv_ping_packets_first" |
974 | then | 975 | then |
975 | ac_cv_ping_packets_first=yes | 976 | ac_cv_ping_packets_first=yes |
976 | dnl AC_DEFINE_UNQUOTED(PING_PACKETS_FIRST,"$ac_cv_ping_command", | ||
977 | dnl [Define if packet count must precede host]) | ||
978 | fi | 977 | fi |
979 | 978 | ||
980 | elif [[ "z$ac_cv_uname_s" = "zUnixWare" ]] && \ | 979 | elif [[ "z$ac_cv_uname_s" = "zUnixWare" ]] && \ |
981 | $PATH_TO_PING -n -s 127.0.0.1 56 1 2>/dev/null | \ | 980 | $PATH_TO_PING -n -s 127.0.0.1 56 1 2>/dev/null | \ |
982 | egrep -i "^round-trip|^rtt" >/dev/null | 981 | egrep -i "^round-trip|^rtt" >/dev/null |
983 | then | 982 | then |
984 | ac_cv_ping_command="$PATH_TO_PING -n -U -c %d %s" | 983 | with_ping_command="$PATH_TO_PING -n -U -c %d %s" |
985 | ac_cv_ping_packets_first=yes | 984 | ac_cv_ping_packets_first=yes |
986 | AC_MSG_RESULT([$ac_cv_ping_command]) | 985 | AC_MSG_RESULT([$with_ping_command]) |
987 | 986 | ||
988 | elif $PATH_TO_PING -n -U -c 1 127.0.0.1 2>/dev/null | \ | 987 | elif $PATH_TO_PING -n -U -c 1 127.0.0.1 2>/dev/null | \ |
989 | egrep -i "^round-trip|^rtt" >/dev/null | 988 | egrep -i "^round-trip|^rtt" >/dev/null |
990 | then | 989 | then |
991 | ac_cv_ping_command="$PATH_TO_PING -n -U -c %d %s" | 990 | with_ping_command="$PATH_TO_PING -n -U -c %d %s" |
992 | ac_cv_ping_packets_first=yes | 991 | ac_cv_ping_packets_first=yes |
993 | AC_MSG_RESULT([$ac_cv_ping_command]) | 992 | AC_MSG_RESULT([$with_ping_command]) |
994 | 993 | ||
995 | elif $PATH_TO_PING -n -c 1 127.0.0.1 2>/dev/null | \ | 994 | elif $PATH_TO_PING -n -c 1 127.0.0.1 2>/dev/null | \ |
996 | egrep -i "^round-trip|^rtt" >/dev/null | 995 | egrep -i "^round-trip|^rtt" >/dev/null |
997 | then | 996 | then |
998 | ac_cv_ping_command="$PATH_TO_PING -n -c %d %s" | 997 | with_ping_command="$PATH_TO_PING -n -c %d %s" |
999 | ac_cv_ping_packets_first=yes | 998 | ac_cv_ping_packets_first=yes |
1000 | AC_MSG_RESULT([$ac_cv_ping_command]) | 999 | AC_MSG_RESULT([$with_ping_command]) |
1001 | 1000 | ||
1002 | elif $PATH_TO_PING -n 127.0.0.1 -c 1 2>/dev/null | \ | 1001 | elif $PATH_TO_PING -n 127.0.0.1 -c 1 2>/dev/null | \ |
1003 | egrep -i "^round-trip|^rtt" >/dev/null | 1002 | egrep -i "^round-trip|^rtt" >/dev/null |
1004 | then | 1003 | then |
1005 | ac_cv_ping_command="$PATH_TO_PING -n %s -c %d" | 1004 | with_ping_command="$PATH_TO_PING -n %s -c %d" |
1006 | AC_MSG_RESULT([$ac_cv_ping_command]) | 1005 | AC_MSG_RESULT([$with_ping_command]) |
1007 | 1006 | ||
1008 | elif $PATH_TO_PING 127.0.0.1 -n 1 2>/dev/null | \ | 1007 | elif $PATH_TO_PING 127.0.0.1 -n 1 2>/dev/null | \ |
1009 | egrep -i "^round-trip|^rtt" >/dev/null | 1008 | egrep -i "^round-trip|^rtt" >/dev/null |
1010 | then | 1009 | then |
1011 | ac_cv_ping_command="$PATH_TO_PING %s -n %d" | 1010 | with_ping_command="$PATH_TO_PING %s -n %d" |
1012 | AC_MSG_RESULT([$ac_cv_ping_command]) | 1011 | AC_MSG_RESULT([$with_ping_command]) |
1013 | 1012 | ||
1014 | elif $PATH_TO_PING -n -s 127.0.0.1 56 1 2>/dev/null | \ | 1013 | elif $PATH_TO_PING -n -s 127.0.0.1 56 1 2>/dev/null | \ |
1015 | egrep -i "^round-trip|^rtt" >/dev/null | 1014 | egrep -i "^round-trip|^rtt" >/dev/null |
1016 | then | 1015 | then |
1017 | ac_cv_ping_command="$PATH_TO_PING -n -s %s 56 %d" | 1016 | with_ping_command="$PATH_TO_PING -n -s %s 56 %d" |
1018 | AC_MSG_RESULT([$ac_cv_ping_command]) | 1017 | AC_MSG_RESULT([$with_ping_command]) |
1019 | 1018 | ||
1020 | elif $PATH_TO_PING -n -h 127.0.0.1 -s 56 -c 1 2>/dev/null | \ | 1019 | elif $PATH_TO_PING -n -h 127.0.0.1 -s 56 -c 1 2>/dev/null | \ |
1021 | egrep -i "^round-trip|^rtt" >/dev/null | 1020 | egrep -i "^round-trip|^rtt" >/dev/null |
1022 | then | 1021 | then |
1023 | ac_cv_ping_command="$PATH_TO_PING -n -h %s -s 56 -c %d" | 1022 | with_ping_command="$PATH_TO_PING -n -h %s -s 56 -c %d" |
1024 | AC_MSG_RESULT([$ac_cv_ping_command]) | 1023 | AC_MSG_RESULT([$with_ping_command]) |
1025 | 1024 | ||
1026 | elif $PATH_TO_PING -n -s 56 -c 1 127.0.0.1 2>/dev/null | \ | 1025 | elif $PATH_TO_PING -n -s 56 -c 1 127.0.0.1 2>/dev/null | \ |
1027 | egrep -i "^round-trip|^rtt" >/dev/null | 1026 | egrep -i "^round-trip|^rtt" >/dev/null |
1028 | then | 1027 | then |
1029 | ac_cv_ping_command="$PATH_TO_PING -n -s 56 -c %d %s" | 1028 | with_ping_command="$PATH_TO_PING -n -s 56 -c %d %s" |
1030 | ac_cv_ping_packets_first=yes | 1029 | ac_cv_ping_packets_first=yes |
1031 | AC_MSG_RESULT([$ac_cv_ping_command]) | 1030 | AC_MSG_RESULT([$with_ping_command]) |
1032 | 1031 | ||
1033 | elif $PATH_TO_PING -n -c 1 127.0.0.1 2>/dev/null | \ | 1032 | elif $PATH_TO_PING -n -c 1 127.0.0.1 2>/dev/null | \ |
1034 | egrep -i "^round-trip|^rtt" >/dev/null | 1033 | egrep -i "^round-trip|^rtt" >/dev/null |
1035 | then | 1034 | then |
1036 | ac_cv_ping_command="$PATH_TO_PING -n -c %d %s" | 1035 | with_ping_command="$PATH_TO_PING -n -c %d %s" |
1037 | ac_cv_ping_packets_first=yes | 1036 | ac_cv_ping_packets_first=yes |
1038 | AC_MSG_RESULT([$ac_cv_ping_command]) | 1037 | AC_MSG_RESULT([$with_ping_command]) |
1039 | 1038 | ||
1040 | else | 1039 | else |
1041 | AC_MSG_WARN([unable to find usable ping syntax]) | 1040 | AC_MSG_WARN([unable to find usable ping syntax]) |
1042 | fi | 1041 | fi |
1043 | 1042 | ||
1044 | AC_DEFINE_UNQUOTED(PING_COMMAND,"$ac_cv_ping_command", | 1043 | AC_DEFINE_UNQUOTED(PING_COMMAND,"$with_ping_command", |
1045 | [path and args for ICMP ping command]) | 1044 | [path and args for ICMP ping command]) |
1046 | 1045 | ||
1047 | if test "x$ac_cv_ping_packets_first" != "xno" | 1046 | if test "x$ac_cv_ping_packets_first" != "xno" |
@@ -1053,14 +1052,14 @@ fi | |||
1053 | AC_ARG_WITH(ping6_command, | 1052 | AC_ARG_WITH(ping6_command, |
1054 | ACX_HELP_STRING([--with-ping6-command=SYNTAX], | 1053 | ACX_HELP_STRING([--with-ping6-command=SYNTAX], |
1055 | [sets syntax for ICMPv6 ping]), | 1054 | [sets syntax for ICMPv6 ping]), |
1056 | ac_cv_ping6_command=$withval,) | 1055 | with_ping6_command=$withval,) |
1057 | 1056 | ||
1058 | if test x"$ac_cv_sys_use_ipv6" != xno ; then | 1057 | if test x"$with_ipv6" != xno ; then |
1059 | AC_MSG_CHECKING(for ICMPv6 ping syntax) | 1058 | AC_MSG_CHECKING(for ICMPv6 ping syntax) |
1060 | ac_cv_ping6_packets_first=no | 1059 | ac_cv_ping6_packets_first=no |
1061 | if test -n "$ac_cv_ping6_command" | 1060 | if test -n "$with_ping6_command" |
1062 | then | 1061 | then |
1063 | AC_MSG_RESULT([(command-line) $ac_cv_ping6_command]) | 1062 | AC_MSG_RESULT([(command-line) $with_ping6_command]) |
1064 | if test -n "$ac_cv_ping6_packets_first" | 1063 | if test -n "$ac_cv_ping6_packets_first" |
1065 | then | 1064 | then |
1066 | ac_cv_ping6_packets_first=yes | 1065 | ac_cv_ping6_packets_first=yes |
@@ -1071,61 +1070,61 @@ elif test "x$PATH_TO_PING6" != "x"; then | |||
1071 | $PATH_TO_PING6 -n -s ::1 56 1 2>/dev/null | \ | 1070 | $PATH_TO_PING6 -n -s ::1 56 1 2>/dev/null | \ |
1072 | egrep -i "^round-trip|^rtt" >/dev/null | 1071 | egrep -i "^round-trip|^rtt" >/dev/null |
1073 | then | 1072 | then |
1074 | ac_cv_ping6_command="$PATH_TO_PING6 -n -U -c %d %s" | 1073 | with_ping6_command="$PATH_TO_PING6 -n -U -c %d %s" |
1075 | ac_cv_ping6_packets_first=yes | 1074 | ac_cv_ping6_packets_first=yes |
1076 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1075 | AC_MSG_RESULT([$with_ping6_command]) |
1077 | 1076 | ||
1078 | elif $PATH_TO_PING6 -n -U -c 1 ::1 2>/dev/null | \ | 1077 | elif $PATH_TO_PING6 -n -U -c 1 ::1 2>/dev/null | \ |
1079 | egrep -i "^round-trip|^rtt" >/dev/null | 1078 | egrep -i "^round-trip|^rtt" >/dev/null |
1080 | then | 1079 | then |
1081 | ac_cv_ping6_command="$PATH_TO_PING6 -n -U -c %d %s" | 1080 | with_ping6_command="$PATH_TO_PING6 -n -U -c %d %s" |
1082 | ac_cv_ping6_packets_first=yes | 1081 | ac_cv_ping6_packets_first=yes |
1083 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1082 | AC_MSG_RESULT([$with_ping6_command]) |
1084 | 1083 | ||
1085 | elif $PATH_TO_PING6 -n -c 1 ::1 2>/dev/null | \ | 1084 | elif $PATH_TO_PING6 -n -c 1 ::1 2>/dev/null | \ |
1086 | egrep -i "^round-trip|^rtt" >/dev/null | 1085 | egrep -i "^round-trip|^rtt" >/dev/null |
1087 | then | 1086 | then |
1088 | ac_cv_ping6_command="$PATH_TO_PING6 -n -c %d %s" | 1087 | with_ping6_command="$PATH_TO_PING6 -n -c %d %s" |
1089 | ac_cv_ping6_packets_first=yes | 1088 | ac_cv_ping6_packets_first=yes |
1090 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1089 | AC_MSG_RESULT([$with_ping6_command]) |
1091 | 1090 | ||
1092 | elif $PATH_TO_PING6 -n ::1 -c 1 2>/dev/null | \ | 1091 | elif $PATH_TO_PING6 -n ::1 -c 1 2>/dev/null | \ |
1093 | egrep -i "^round-trip|^rtt" >/dev/null | 1092 | egrep -i "^round-trip|^rtt" >/dev/null |
1094 | then | 1093 | then |
1095 | ac_cv_ping6_command="$PATH_TO_PING6 -n %s -c %d" | 1094 | with_ping6_command="$PATH_TO_PING6 -n %s -c %d" |
1096 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1095 | AC_MSG_RESULT([$with_ping6_command]) |
1097 | 1096 | ||
1098 | elif $PATH_TO_PING6 ::1 -n 1 2>/dev/null | \ | 1097 | elif $PATH_TO_PING6 ::1 -n 1 2>/dev/null | \ |
1099 | egrep -i "^round-trip|^rtt" >/dev/null | 1098 | egrep -i "^round-trip|^rtt" >/dev/null |
1100 | then | 1099 | then |
1101 | ac_cv_ping6_command="$PATH_TO_PING6 %s -n %d" | 1100 | with_ping6_command="$PATH_TO_PING6 %s -n %d" |
1102 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1101 | AC_MSG_RESULT([$with_ping6_command]) |
1103 | 1102 | ||
1104 | elif $PATH_TO_PING6 -n -s ::1 56 1 2>/dev/null | \ | 1103 | elif $PATH_TO_PING6 -n -s ::1 56 1 2>/dev/null | \ |
1105 | egrep -i "^round-trip|^rtt" >/dev/null | 1104 | egrep -i "^round-trip|^rtt" >/dev/null |
1106 | then | 1105 | then |
1107 | ac_cv_ping6_command="$PATH_TO_PING6 -n -s %s 56 %d" | 1106 | with_ping6_command="$PATH_TO_PING6 -n -s %s 56 %d" |
1108 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1107 | AC_MSG_RESULT([$with_ping6_command]) |
1109 | 1108 | ||
1110 | elif $PATH_TO_PING6 -n -h ::1 -s 56 -c 1 2>/dev/null | \ | 1109 | elif $PATH_TO_PING6 -n -h ::1 -s 56 -c 1 2>/dev/null | \ |
1111 | egrep -i "^round-trip|^rtt" >/dev/null | 1110 | egrep -i "^round-trip|^rtt" >/dev/null |
1112 | then | 1111 | then |
1113 | ac_cv_ping6_command="$PATH_TO_PING6 -n -h %s -s 56 -c %d" | 1112 | with_ping6_command="$PATH_TO_PING6 -n -h %s -s 56 -c %d" |
1114 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1113 | AC_MSG_RESULT([$with_ping6_command]) |
1115 | 1114 | ||
1116 | elif $PATH_TO_PING6 -n -s 56 -c 1 ::1 2>/dev/null | \ | 1115 | elif $PATH_TO_PING6 -n -s 56 -c 1 ::1 2>/dev/null | \ |
1117 | egrep -i "^round-trip|^rtt" >/dev/null | 1116 | egrep -i "^round-trip|^rtt" >/dev/null |
1118 | then | 1117 | then |
1119 | ac_cv_ping6_command="$PATH_TO_PING6 -n -s 56 -c %d %s" | 1118 | with_ping6_command="$PATH_TO_PING6 -n -s 56 -c %d %s" |
1120 | ac_cv_ping6_packets_first=yes | 1119 | ac_cv_ping6_packets_first=yes |
1121 | AC_MSG_RESULT([$ac_cv_ping_command]) | 1120 | AC_MSG_RESULT([$with_ping_command]) |
1122 | 1121 | ||
1123 | elif $PATH_TO_PING6 -n -c 1 ::1 2>/dev/null | \ | 1122 | elif $PATH_TO_PING6 -n -c 1 ::1 2>/dev/null | \ |
1124 | egrep -i "^round-trip|^rtt" >/dev/null | 1123 | egrep -i "^round-trip|^rtt" >/dev/null |
1125 | then | 1124 | then |
1126 | ac_cv_ping6_command="$PATH_TO_PING6 -n -c %d %s" | 1125 | with_ping6_command="$PATH_TO_PING6 -n -c %d %s" |
1127 | ac_cv_ping6_packets_first=yes | 1126 | ac_cv_ping6_packets_first=yes |
1128 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1127 | AC_MSG_RESULT([$with_ping6_command]) |
1129 | 1128 | ||
1130 | fi | 1129 | fi |
1131 | 1130 | ||
@@ -1134,68 +1133,68 @@ elif test "x$PATH_TO_PING" != "x"; then | |||
1134 | $PATH_TO_PING -A inet6 -n -s ::1 56 1 2>/dev/null | \ | 1133 | $PATH_TO_PING -A inet6 -n -s ::1 56 1 2>/dev/null | \ |
1135 | egrep -i "^round-trip|^rtt" >/dev/null | 1134 | egrep -i "^round-trip|^rtt" >/dev/null |
1136 | then | 1135 | then |
1137 | ac_cv_ping6_command="$PATH_TO_PING -A inet6 -n -U -c %d %s" | 1136 | with_ping6_command="$PATH_TO_PING -A inet6 -n -U -c %d %s" |
1138 | ac_cv_ping6_packets_first=yes | 1137 | ac_cv_ping6_packets_first=yes |
1139 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1138 | AC_MSG_RESULT([$with_ping6_command]) |
1140 | 1139 | ||
1141 | elif $PATH_TO_PING -A inet6 -n -U -c 1 ::1 2>/dev/null | \ | 1140 | elif $PATH_TO_PING -A inet6 -n -U -c 1 ::1 2>/dev/null | \ |
1142 | egrep -i "^round-trip|^rtt" >/dev/null | 1141 | egrep -i "^round-trip|^rtt" >/dev/null |
1143 | then | 1142 | then |
1144 | ac_cv_ping6_command="$PATH_TO_PING -A inet6 -n -U -c %d %s" | 1143 | with_ping6_command="$PATH_TO_PING -A inet6 -n -U -c %d %s" |
1145 | ac_cv_ping6_packets_first=yes | 1144 | ac_cv_ping6_packets_first=yes |
1146 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1145 | AC_MSG_RESULT([$with_ping6_command]) |
1147 | 1146 | ||
1148 | elif $PATH_TO_PING -A inet6 -n -c 1 ::1 2>/dev/null | \ | 1147 | elif $PATH_TO_PING -A inet6 -n -c 1 ::1 2>/dev/null | \ |
1149 | egrep -i "^round-trip|^rtt" >/dev/null | 1148 | egrep -i "^round-trip|^rtt" >/dev/null |
1150 | then | 1149 | then |
1151 | ac_cv_ping6_command="$PATH_TO_PING -A inet6 -n -c %d %s" | 1150 | with_ping6_command="$PATH_TO_PING -A inet6 -n -c %d %s" |
1152 | ac_cv_ping6_packets_first=yes | 1151 | ac_cv_ping6_packets_first=yes |
1153 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1152 | AC_MSG_RESULT([$with_ping6_command]) |
1154 | 1153 | ||
1155 | elif $PATH_TO_PING -A inet6 -n ::1 -c 1 2>/dev/null | \ | 1154 | elif $PATH_TO_PING -A inet6 -n ::1 -c 1 2>/dev/null | \ |
1156 | egrep -i "^round-trip|^rtt" >/dev/null | 1155 | egrep -i "^round-trip|^rtt" >/dev/null |
1157 | then | 1156 | then |
1158 | ac_cv_ping6_command="$PATH_TO_PING -A inet6 -n %s -c %d" | 1157 | with_ping6_command="$PATH_TO_PING -A inet6 -n %s -c %d" |
1159 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1158 | AC_MSG_RESULT([$with_ping6_command]) |
1160 | 1159 | ||
1161 | elif $PATH_TO_PING -A inet6 ::1 -n 1 2>/dev/null | \ | 1160 | elif $PATH_TO_PING -A inet6 ::1 -n 1 2>/dev/null | \ |
1162 | egrep -i "^round-trip|^rtt" >/dev/null | 1161 | egrep -i "^round-trip|^rtt" >/dev/null |
1163 | then | 1162 | then |
1164 | ac_cv_ping6_command="$PATH_TO_PING -A inet6 %s -n %d" | 1163 | with_ping6_command="$PATH_TO_PING -A inet6 %s -n %d" |
1165 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1164 | AC_MSG_RESULT([$with_ping6_command]) |
1166 | 1165 | ||
1167 | elif $PATH_TO_PING -A inet6 -n -s ::1 56 1 2>/dev/null | \ | 1166 | elif $PATH_TO_PING -A inet6 -n -s ::1 56 1 2>/dev/null | \ |
1168 | egrep -i "^round-trip|^rtt" >/dev/null | 1167 | egrep -i "^round-trip|^rtt" >/dev/null |
1169 | then | 1168 | then |
1170 | ac_cv_ping6_command="$PATH_TO_PING -A inet6 -n -s %s 56 %d" | 1169 | with_ping6_command="$PATH_TO_PING -A inet6 -n -s %s 56 %d" |
1171 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1170 | AC_MSG_RESULT([$with_ping6_command]) |
1172 | 1171 | ||
1173 | elif $PATH_TO_PING -A inet6 -n -h ::1 -s 56 -c 1 2>/dev/null | \ | 1172 | elif $PATH_TO_PING -A inet6 -n -h ::1 -s 56 -c 1 2>/dev/null | \ |
1174 | egrep -i "^round-trip|^rtt" >/dev/null | 1173 | egrep -i "^round-trip|^rtt" >/dev/null |
1175 | then | 1174 | then |
1176 | ac_cv_ping6_command="$PATH_TO_PING -A inet6 -n -h %s -s 56 -c %d" | 1175 | with_ping6_command="$PATH_TO_PING -A inet6 -n -h %s -s 56 -c %d" |
1177 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1176 | AC_MSG_RESULT([$with_ping6_command]) |
1178 | 1177 | ||
1179 | elif $PATH_TO_PING -A inet6 -n -s 56 -c 1 ::1 2>/dev/null | \ | 1178 | elif $PATH_TO_PING -A inet6 -n -s 56 -c 1 ::1 2>/dev/null | \ |
1180 | egrep -i "^round-trip|^rtt" >/dev/null | 1179 | egrep -i "^round-trip|^rtt" >/dev/null |
1181 | then | 1180 | then |
1182 | ac_cv_ping6_command="$PATH_TO_PING -A inet6 -n -s 56 -c %d %s" | 1181 | with_ping6_command="$PATH_TO_PING -A inet6 -n -s 56 -c %d %s" |
1183 | ac_cv_ping6_packets_first=yes | 1182 | ac_cv_ping6_packets_first=yes |
1184 | AC_MSG_RESULT([$ac_cv_ping_command]) | 1183 | AC_MSG_RESULT([$with_ping_command]) |
1185 | 1184 | ||
1186 | elif $PATH_TO_PING -A inet6 -n -c 1 ::1 2>/dev/null | \ | 1185 | elif $PATH_TO_PING -A inet6 -n -c 1 ::1 2>/dev/null | \ |
1187 | egrep -i "^round-trip|^rtt" >/dev/null | 1186 | egrep -i "^round-trip|^rtt" >/dev/null |
1188 | then | 1187 | then |
1189 | ac_cv_ping6_command="$PATH_TO_PING -A inet6 -n -c %d %s" | 1188 | with_ping6_command="$PATH_TO_PING -A inet6 -n -c %d %s" |
1190 | ac_cv_ping6_packets_first=yes | 1189 | ac_cv_ping6_packets_first=yes |
1191 | AC_MSG_RESULT([$ac_cv_ping6_command]) | 1190 | AC_MSG_RESULT([$with_ping6_command]) |
1192 | 1191 | ||
1193 | fi | 1192 | fi |
1194 | 1193 | ||
1195 | fi | 1194 | fi |
1196 | 1195 | ||
1197 | if test "x$ac_cv_ping6_command" != "x"; then | 1196 | if test "x$with_ping6_command" != "x"; then |
1198 | AC_DEFINE_UNQUOTED(PING6_COMMAND,"$ac_cv_ping6_command", | 1197 | AC_DEFINE_UNQUOTED(PING6_COMMAND,"$with_ping6_command", |
1199 | [path and args for ICMPv6 ping command]) | 1198 | [path and args for ICMPv6 ping command]) |
1200 | else | 1199 | else |
1201 | AC_MSG_RESULT([none]) | 1200 | AC_MSG_RESULT([none]) |
@@ -1464,13 +1463,13 @@ AC_DEFINE_UNQUOTED(PACKAGE_VERSION,"${VERSION}",[package version]) | |||
1464 | 1463 | ||
1465 | 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) | 1464 | 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) |
1466 | 1465 | ||
1467 | ACX_FEATURE([with],[cgiurl],[$cgiurl]) | 1466 | ACX_FEATURE([with],[cgiurl]) |
1468 | ACX_FEATURE([with],[nagios-user],[$nagios_usr]) | 1467 | ACX_FEATURE([with],[nagios-user]) |
1469 | ACX_FEATURE([with],[nagios-group],[$nagios_grp]) | 1468 | ACX_FEATURE([with],[nagios-group]) |
1470 | ACX_FEATURE([with],[trusted-path],[$trusted_path]) | 1469 | ACX_FEATURE([with],[trusted-path]) |
1471 | ACX_FEATURE([with],[df-command],[$ac_cv_df_command]) | 1470 | ACX_FEATURE([with],[df-command]) |
1472 | ACX_FEATURE([with],[ping-command],[$ac_cv_ping_command]) | 1471 | ACX_FEATURE([with],[ping-command]) |
1473 | ACX_FEATURE([with],[ping6-command],[$ac_cv_ping6_command]) | 1472 | ACX_FEATURE([with],[ping6-command]) |
1474 | ACX_FEATURE([with],[lwres]) | 1473 | ACX_FEATURE([with],[lwres]) |
1475 | ACX_FEATURE([with],[ipv6],[$ac_cv_sys_use_ipv6]) | 1474 | ACX_FEATURE([with],[ipv6]) |
1476 | ACX_FEATURE([enable],[emulate-getaddrinfo]) | 1475 | ACX_FEATURE([enable],[emulate-getaddrinfo]) |
diff --git a/plugins-scripts/subst.in b/plugins-scripts/subst.in index 5b70fbed..7e38e027 100644 --- a/plugins-scripts/subst.in +++ b/plugins-scripts/subst.in | |||
@@ -51,11 +51,11 @@ BEGIN { | |||
51 | # Trusted path mechanism (deprecated) | 51 | # Trusted path mechanism (deprecated) |
52 | 52 | ||
53 | /^[ \t]*\$ENV[ \t]*\{[ \t'"]*PATH[ \t"']*\}[ \t]*=/ { | 53 | /^[ \t]*\$ENV[ \t]*\{[ \t'"]*PATH[ \t"']*\}[ \t]*=/ { |
54 | sub(/\=[ \t]*['"][^"']+["']/,"='@trusted_path@' # autoconf-derived"); | 54 | sub(/\=[ \t]*['"][^"']+["']/,"='@with_trusted_path@' # autoconf-derived"); |
55 | } | 55 | } |
56 | 56 | ||
57 | /^[\t ]*(export[\t ]*)?PATH[\t ]*=['"]+.+["']$/ { | 57 | /^[\t ]*(export[\t ]*)?PATH[\t ]*=['"]+.+["']$/ { |
58 | sub(/\=.*$/,"='@trusted_path@' # autoconf-derived"); | 58 | sub(/\=.*$/,"='@with_trusted_path@' # autoconf-derived"); |
59 | } | 59 | } |
60 | 60 | ||
61 | # Specific programs | 61 | # Specific programs |