1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
|
--- configure.in.orig Wed Dec 1 09:41:08 2004
+++ configure.in Fri Dec 3 22:27:18 2004
@@ -10,7 +10,7 @@
RELEASE=1
AC_SUBST(RELEASE)
-AC_PREFIX_DEFAULT(/usr/local/nagios)
+dnl AC_PREFIX_DEFAULT(/usr/local/nagios)
dnl Figure out how to invoke "install" and what install options to use.
AC_PROG_INSTALL
@@ -71,8 +71,6 @@
with_nagios_group=nagios)
AC_SUBST(with_nagios_user)
AC_SUBST(with_nagios_group)
-INSTALL_OPTS="-o $with_nagios_user -g $with_nagios_group"
-AC_SUBST(INSTALL_OPTS)
AC_ARG_WITH(trusted_path,
ACX_HELP_STRING([--with-trusted-path=PATH],
@@ -181,27 +179,35 @@
LIBS="$_SAVEDLIBS"
CPPFLAGS="$_SAVEDCPPFLAGS"
+AC_ARG_ENABLE(radius,--enable-radius compile check_radius)
+if test x$enable_radius = xyes; then
dnl Check for radius libraries
_SAVEDLIBS="$LIBS"
-AC_CHECK_LIB(radiusclient,rc_read_config)
+AC_CHECK_LIB(radiusclient,rc_read_config,,,-L${LOCALBASE}/lib)
if test "$ac_cv_lib_radiusclient_rc_read_config" = "yes"; then
EXTRAS="$EXTRAS check_radius"
- RADIUSLIBS="-lradiusclient"
+ RADIUSLIBS="-L${LOCALBASE}/lib -lradiusclient"\
+ RADIUSINCLUDE="-I${LOCALBASE}/include"
AC_SUBST(RADIUSLIBS)
+ AC_SUBST(RADIUSINCLUDE)
else
AC_MSG_WARN([Skipping radius plugin])
AC_MSG_WARN([install radius libs to compile this plugin (see REQUIREMENTS).])
fi
LIBS="$_SAVEDLIBS"
+fi
+AC_ARG_ENABLE(ldap,--enable-ldap compile check_ldap)
+if test x$enable_ldap = xyes; then
dnl Check for LDAP libraries
_SAVEDLIBS="$LIBS"
-AC_CHECK_LIB(ldap,main,,,-llber)
-if test "$ac_cv_lib_ldap_main" = "yes"; then
- LDAPLIBS="-lldap -llber"\
- LDAPINCLUDE="-I/usr/include/ldap"
+AC_CHECK_LIB(ldap,ldap_simple_bind,,,-L${LOCALBASE}/lib -llber)
+if test "$ac_cv_lib_ldap_ldap_simple_bind" = "yes"; then
+ LDAPLIBS="-L${LOCALBASE}/lib -lldap -llber"\
+ LDAPINCLUDE="-I${LOCALBASE}/include"
AC_SUBST(LDAPLIBS)
AC_SUBST(LDAPINCLUDE)
+ LIBS="-L${LOCALBASE}/lib $LIBS"
AC_CHECK_FUNCS(ldap_set_option)
EXTRAS="$EXTRAS check_ldap"
else
@@ -209,6 +215,7 @@
AC_MSG_WARN([install LDAP libs to compile this plugin (see REQUIREMENTS).])
fi
LIBS="$_SAVEDLIBS"
+fi
dnl Check for mysql libraries
@@ -676,7 +683,7 @@
egrep -i ["^STAT +COMMAND +VSZ +RSS +UID +USER +PPID"] >/dev/null
then
ac_cv_ps_varlist="[procstat,&procuid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
- ac_cv_ps_command="$PATH_TO_PS waxco 'state uid ppid vsz rss pcpu command command'"
+ ac_cv_ps_command="$PATH_TO_PS -axwo 'state uid ppid vsz rss pcpu command command'"
ac_cv_ps_format="%s %d %d %d %d %f %s %n"
ac_cv_ps_cols=8
AC_MSG_RESULT([$ac_cv_ps_command])
@@ -1221,6 +1228,8 @@
AC_DEFINE_UNQUOTED(WHO_COMMAND,"$ac_cv_path_to_who",
[path and arguments for invoking 'who'])
+AC_ARG_ENABLE(snmp,--enable-snmp compile check_hpjd and check_snmp)
+if test x$enable_snmp = xyes; then
AC_PATH_PROG(PATH_TO_SNMPGET,snmpget)
if test -x "$PATH_TO_SNMPGET"
then
@@ -1243,7 +1252,10 @@
else
AC_MSG_WARN([Tried $PERL - install Net::SNMP perl module if you want to use the perl snmp plugins])
fi
+fi
+AC_ARG_ENABLE(qstat,--enable-qstat compile check_game)
+if test x$enable_qstat = xyes; then
AC_PATH_PROG(PATH_TO_QUAKESTAT,quakestat)
AC_PATH_PROG(PATH_TO_QSTAT,qstat)
@@ -1265,7 +1277,10 @@
AC_DEFINE_UNQUOTED(PATH_TO_QSTAT,"$ac_cv_path_to_qstat",
[path to qstat/quakestat])
fi
+fi
+AC_ARG_ENABLE(fping,--enable-fping compile check_fping)
+if test x$enable_fping = xyes; then
AC_PATH_PROG(PATH_TO_FPING,fping)
if test -x "$PATH_TO_FPING"
then
@@ -1273,6 +1288,7 @@
EXTRAS="$EXTRAS check_fping"
else
AC_MSG_WARN([Get fping from http://www.fping.com in order to make check_fping plugin])
+fi
fi
AC_PATH_PROG(PATH_TO_SSH,ssh)
|