if test $mysql_config_status -ne 0
then
- with_libmysql="no"
+ with_libmysql="no ($with_mysql_config failed)"
else
SAVE_CPPFLAGS="$CPPFLAGS"
CPPFLAGS="$CPPFLAGS $with_mysql_cflags"
- AC_CHECK_HEADERS(mysql/mysql.h, [], [with_libmysql="no (mysql/mysql.h not found)"], [])
+ have_mysql_h="no"
+ have_mysql_mysql_h="no"
+ AC_CHECK_HEADERS(mysql.h, [have_mysql_h="yes"])
+
+ if test "x$have_mysql_h" = "xno"
+ then
+ AC_CHECK_HEADERS(mysql/mysql.h, [have_mysql_mysql_h="yes"])
+ fi
+
+ if test "x$have_mysql_h$have_mysql_mysql_h" = "xnono"
+ then
+ with_libmysql="no (mysql.h not found)"
+ fi
CPPFLAGS="$SAVE_CPPFLAGS"
fi
if test $mysql_config_status -ne 0
then
- with_libmysql="no"
+ with_libmysql="no ($with_mysql_config failed)"
else
AC_CHECK_LIB(mysqlclient, mysql_init,
[with_libmysql="yes"],
AM_CONDITIONAL(BUILD_WITH_OWN_LIBOPING, test "x$with_own_liboping" = "xyes")
# }}}
+# --with-oracle {{{
+with_oracle_cppflags=""
+with_oracle_libs=""
+AC_ARG_WITH(oracle, [AS_HELP_STRING([--with-oracle@<:@=ORACLE_HOME@:>@], [Path to Oracle.])],
+[
+ if test "x$withval" = "xyes"
+ then
+ if test "x$ORACLE_HOME" = "x"
+ then
+ AC_MSG_WARN([Use of the Oracle library has been forced, but the environment variable ORACLE_HOME is not set.])
+ fi
+ with_oracle="yes"
+ else if test "x$withval" = "xno"
+ then
+ with_oracle="no"
+ else
+ with_oracle="yes"
+ ORACLE_HOME="$withval"
+ fi; fi
+],
+[
+ if test "x$ORACLE_HOME" = "x"
+ then
+ with_oracle="no (ORACLE_HOME is not set)"
+ else
+ with_oracle="yes"
+ fi
+])
+if test "x$ORACLE_HOME" != "x"
+then
+ with_oracle_cppflags="-I$ORACLE_HOME/rdbms/public"
+
+ if test -e "$ORACLE_HOME/lib/ldflags"
+ then
+ with_oracle_libs=`cat "$ORACLE_HOME/lib/ldflags"`
+ fi
+ #with_oracle_libs="-L$ORACLE_HOME/lib $with_oracle_libs -lclntsh"
+ with_oracle_libs="-L$ORACLE_HOME/lib -lclntsh"
+fi
+if test "x$with_oracle" = "xyes"
+then
+ SAVE_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS $with_oracle_cppflags"
+
+ AC_CHECK_HEADERS(oci.h, [with_oracle="yes"], [with_oracle="no (oci.h not found)"])
+
+ CPPFLAGS="$SAVE_CPPFLAGS"
+fi
+if test "x$with_oracle" = "xyes"
+then
+ SAVE_CPPFLAGS="$CPPFLAGS"
+ SAVE_LDFLAGS="$LDFLAGS"
+ CPPFLAGS="$CPPFLAGS $with_oracle_cppflags"
+ LDFLAGS="$LDFLAGS $with_oracle_libs"
+
+ AC_CHECK_FUNC(OCIEnvCreate, [with_oracle="yes"], [with_oracle="no (Symbol 'OCIEnvCreate' not found)"])
+
+ CPPFLAGS="$SAVE_CPPFLAGS"
+ LDFLAGS="$SAVE_LDFLAGS"
+fi
+if test "x$with_oracle" = "xyes"
+then
+ BUILD_WITH_ORACLE_CFLAGS="$with_oracle_cppflags"
+ BUILD_WITH_ORACLE_LIBS="$with_oracle_libs"
+ AC_SUBST(BUILD_WITH_ORACLE_CFLAGS)
+ AC_SUBST(BUILD_WITH_ORACLE_LIBS)
+fi
+# }}}
+
# --with-libowcapi {{{
with_libowcapi_cppflags=""
with_libowcapi_libs="-lowcapi"
AM_CONDITIONAL(BUILD_WITH_LIBPCAP, test "x$with_libpcap" = "xyes")
# }}}
+# --with-libpcre {{{
+with_pcre_config="pcre-config"
+with_pcre_cflags=""
+with_pcre_libs=""
+AC_ARG_WITH(libpcre, [AS_HELP_STRING([--with-libpcre@<:@=PREFIX@:>@],
+ [Path to libpcre.])],
+ [
+ if test "x$withval" = "xno"
+ then
+ with_libpcre="no"
+ else if test "x$withval" = "xyes"
+ then
+ with_libpcre="yes"
+ else
+ if test -f "$withval" && test -x "$withval"
+ then
+ with_pcre_config="$withval"
+ else if test -x "$withval/bin/pcre-config"
+ then
+ with_pcre_config="$withval/bin/pcre-config"
+ fi; fi
+ with_libpcre="yes"
+ fi; fi
+ ],
+ [
+ with_libpcre="yes"
+ ])
+
+if test "x$with_libpcre" = "xyes"
+then
+ with_pcre_cflags=`$with_pcre_config --cflags 2>/dev/null`
+ pcre_config_status=$?
+
+ if test $pcre_config_status -ne 0
+ then
+ with_libpcre="no ($with_pcre_config failed)"
+ else
+ SAVE_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS $with_pcre_cflags"
+
+ AC_CHECK_HEADERS(pcre.h, [], [with_libpcre="no (pcre.h not found)"], [])
+
+ CPPFLAGS="$SAVE_CPPFLAGS"
+ fi
+fi
+
+if test "x$with_libpcre" = "xyes"
+then
+ with_pcre_libs=`$with_pcre_config --libs 2>/dev/null`
+ pcre_config_status=$?
+
+ if test $pcre_config_status -ne 0
+ then
+ with_libpcre="no ($with_pcre_config failed)"
+ else
+ AC_CHECK_LIB(pcre, pcre_compile,
+ [with_libpcre="yes"],
+ [with_libpcre="no (symbol 'pcre_compile' not found)"],
+ [$with_pcre_libs])
+ fi
+fi
+
+if test "x$with_libpcre" = "xyes"
+then
+ BUILD_WITH_LIBPCRE_CFLAGS="$with_pcre_cflags"
+ BUILD_WITH_LIBPCRE_LIBS="$with_pcre_libs"
+ AC_SUBST(BUILD_WITH_LIBPCRE_CFLAGS)
+ AC_SUBST(BUILD_WITH_LIBPCRE_LIBS)
+fi
+AM_CONDITIONAL(BUILD_WITH_LIBPCRE, test "x$with_libpcre" = "xyes")
+# }}}
+
# --with-libperl {{{
perl_interpreter="perl"
AC_ARG_WITH(libperl, [AS_HELP_STRING([--with-libperl@<:@=PREFIX@:>@], [Path to libperl.])],
AC_PLUGIN([entropy], [$plugin_entropy], [Entropy statistics])
AC_PLUGIN([exec], [yes], [Execution of external programs])
AC_PLUGIN([filecount], [yes], [Count files in directories])
+AC_PLUGIN([filter_ignore], [yes], [Ignore specific values])
+AC_PLUGIN([filter_pcre], [$with_libpcre], [Filter based on PCRE])
AC_PLUGIN([hddtemp], [yes], [Query hddtempd])
AC_PLUGIN([interface], [$plugin_interface], [Interface traffic statistics])
AC_PLUGIN([iptables], [$with_libiptc], [IPTables rule counters])
AC_PLUGIN([ntpd], [yes], [NTPd statistics])
AC_PLUGIN([nut], [$with_libupsclient], [Network UPS tools statistics])
AC_PLUGIN([onewire], [$with_libowcapi], [OneWire sensor statistics])
+AC_PLUGIN([oracle], [$with_oracle], [Oracle plugin])
AC_PLUGIN([perl], [$plugin_perl], [Embed a Perl interpreter])
AC_PLUGIN([ping], [$with_liboping], [Network latency statistics])
AC_PLUGIN([postgresql], [$with_libpq], [PostgreSQL database statistics])
libopenipmi . . . . . $with_libopenipmipthread
liboping . . . . . . $with_liboping
libpcap . . . . . . . $with_libpcap
+ libpcre . . . . . . . $with_libpcre
libperl . . . . . . . $with_libperl
libpthread . . . . . $with_libpthread
libpq . . . . . . . . $with_libpq
libvirt . . . . . . . $with_libvirt
libxml2 . . . . . . . $with_libxml2
libxmms . . . . . . . $with_libxmms
+ oracle . . . . . . . $with_oracle
Features:
daemon mode . . . . . $enable_daemon
entropy . . . . . . . $enable_entropy
exec . . . . . . . . $enable_exec
filecount . . . . . . $enable_filecount
+ filter_ignore . . . . $enable_filter_ignore
+ filter_pcre . . . . . $enable_filter_pcre
hddtemp . . . . . . . $enable_hddtemp
interface . . . . . . $enable_interface
iptables . . . . . . $enable_iptables
ntpd . . . . . . . . $enable_ntpd
nut . . . . . . . . . $enable_nut
onewire . . . . . . . $enable_onewire
+ oracle . . . . . . . $enable_oracle
perl . . . . . . . . $enable_perl
ping . . . . . . . . $enable_ping
postgresql . . . . . $enable_postgresql