diff options
author | Ton Voon <tonvoon@users.sourceforge.net> | 2006-03-22 17:32:11 +0000 |
---|---|---|
committer | Ton Voon <tonvoon@users.sourceforge.net> | 2006-03-22 17:32:11 +0000 |
commit | c5273a6d8f63f37b502054e97209770e9553c599 (patch) | |
tree | 0d04cd16f99a6aa50423b047afdd36a7611d83df /configure.in | |
parent | 63271bf65d7f6da74e832e16217bac5778d21d6b (diff) | |
download | monitoring-plugins-c5273a6d8f63f37b502054e97209770e9553c599.tar.gz |
Reinstated --with-mysql option
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1347 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 42 |
1 files changed, 27 insertions, 15 deletions
diff --git a/configure.in b/configure.in index 40a323c5..b1efa09c 100644 --- a/configure.in +++ b/configure.in | |||
@@ -12,6 +12,8 @@ AC_SUBST(RELEASE) | |||
12 | 12 | ||
13 | AC_PREFIX_DEFAULT(/usr/local/nagios) | 13 | AC_PREFIX_DEFAULT(/usr/local/nagios) |
14 | 14 | ||
15 | dnl Deprecated configure options | ||
16 | |||
15 | dnl Figure out how to invoke "install" and what install options to use. | 17 | dnl Figure out how to invoke "install" and what install options to use. |
16 | AC_PROG_INSTALL | 18 | AC_PROG_INSTALL |
17 | AC_SUBST(INSTALL) | 19 | AC_SUBST(INSTALL) |
@@ -254,22 +256,31 @@ fi | |||
254 | LIBS="$_SAVEDLIBS" | 256 | LIBS="$_SAVEDLIBS" |
255 | 257 | ||
256 | dnl Check for mysql libraries | 258 | dnl Check for mysql libraries |
257 | AC_PATH_PROG(MYSQLCONFIG, mysql_config) | 259 | AC_ARG_WITH(mysql, |
258 | if test -z "$MYSQLCONFIG"; then | 260 | ACX_HELP_STRING([--with-mysql=DIR], |
259 | AC_MSG_WARN([Skipping mysql plugin]) | 261 | [Compiles mysql plugins. Expects DIR/bin/mysql_config]), |
260 | AC_MSG_WARN([install mysql client libs to compile this plugin (see REQUIREMENTS).]) | 262 | with_mysql=$withval, |
261 | else | 263 | with_mysql=no) |
262 | EXTRAS="$EXTRAS check_mysql check_mysql_query" | 264 | if test $with_mysql != "no" ; then |
263 | MYSQLINCLUDE=`$MYSQLCONFIG --include` | 265 | if test -x $with_mysql/bin/mysql_config ; then |
264 | if test $? != 0 ; then | 266 | MYSQLCONFIG="$with_mysql/bin/mysql_config" |
265 | # mysql_config for 3.x does not support --include | 267 | else |
266 | MYSQLINCLUDE="" | 268 | AC_PATH_PROG(MYSQLCONFIG, mysql_config) |
269 | fi | ||
270 | if test -z "$MYSQLCONFIG"; then | ||
271 | with_mysql="not found" | ||
272 | AC_MSG_WARN([Skipping mysql plugin]) | ||
273 | AC_MSG_WARN([install mysql client libs to compile this plugin (see REQUIREMENTS).]) | ||
274 | else | ||
275 | with_mysql=$MYSQLCONFIG | ||
276 | EXTRAS="$EXTRAS check_mysql check_mysql_query" | ||
277 | MYSQLINCLUDE=`$MYSQLCONFIG --include` | ||
278 | MYSQLLIBS=`$MYSQLCONFIG --libs` | ||
279 | MYSQLCFLAGS=`$MYSQLCONFIG --cflags` | ||
280 | AC_SUBST(MYSQLINCLUDE) | ||
281 | AC_SUBST(MYSQLLIBS) | ||
282 | AC_SUBST(MYSQLCFLAGS) | ||
267 | fi | 283 | fi |
268 | MYSQLLIBS=`$MYSQLCONFIG --libs` | ||
269 | MYSQLCFLAGS=`$MYSQLCONFIG --cflags` | ||
270 | AC_SUBST(MYSQLINCLUDE) | ||
271 | AC_SUBST(MYSQLLIBS) | ||
272 | AC_SUBST(MYSQLCFLAGS) | ||
273 | fi | 284 | fi |
274 | 285 | ||
275 | AC_CHECK_HEADERS(unistd.h) | 286 | AC_CHECK_HEADERS(unistd.h) |
@@ -1730,6 +1741,7 @@ dnl ACX_FEATURE([with],[ps-varlist]) | |||
1730 | 1741 | ||
1731 | ACX_FEATURE([with],[lwres]) | 1742 | ACX_FEATURE([with],[lwres]) |
1732 | ACX_FEATURE([with],[ipv6]) | 1743 | ACX_FEATURE([with],[ipv6]) |
1744 | ACX_FEATURE([with],[mysql]) | ||
1733 | ACX_FEATURE([with],[openssl]) | 1745 | ACX_FEATURE([with],[openssl]) |
1734 | ACX_FEATURE([with],[gnutls]) | 1746 | ACX_FEATURE([with],[gnutls]) |
1735 | ACX_FEATURE([enable],[emulate-getaddrinfo]) | 1747 | ACX_FEATURE([enable],[emulate-getaddrinfo]) |