dnl Process this file with autoconf to produce a configure script.
-AC_INIT(collectd, 3.6.alpha1)
+AC_INIT(collectd, 3.7.0)
AC_CONFIG_SRCDIR(src/collectd.c)
AC_CONFIG_HEADERS(src/config.h)
AM_INIT_AUTOMAKE(dist-bzip2)
AC_PROG_INSTALL
AC_PROG_LN_S
AC_PROG_MAKE_SET
+AM_CONDITIONAL(COMPILER_IS_GCC, test "x$GCC" = "xyes")
dnl configure libtool
AC_DISABLE_STATIC
#
AC_HEADER_SYS_WAIT
AC_HEADER_DIRENT
+AC_CHECK_HEADERS(errno.h)
+AC_CHECK_HEADERS(syslog.h)
AC_CHECK_HEADERS(fcntl.h)
AC_CHECK_HEADERS(signal.h)
+AC_CHECK_HEADERS(assert.h)
+AC_CHECK_HEADERS(sys/types.h)
AC_CHECK_HEADERS(sys/socket.h)
AC_CHECK_HEADERS(sys/select.h)
AC_CHECK_HEADERS(netdb.h)
+AC_CHECK_HEADERS(arpa/inet.h)
+AC_CHECK_HEADERS(netinet/in.h)
AC_CHECK_HEADERS(sys/resource.h)
AC_CHECK_HEADERS(sys/param.h)
-AC_CHECK_HEADERS(errno.h)
-AC_CHECK_HEADERS(syslog.h)
# For cpu modules
AC_CHECK_HEADERS(sys/sysctl.h sys/dkstat.h)
# For load module
AC_CHECK_HEADERS(sys/loadavg.h)
-# For ping module
-AC_CHECK_HEADERS(arpa/inet.h)
-AC_CHECK_HEADERS(netinet/in.h)
-
# For users module
AC_CHECK_HEADERS(utmp.h)
AC_CHECK_HEADERS(utmpx.h)
AC_PROG_GCC_TRADITIONAL
AC_CHECK_FUNCS(gettimeofday select strdup strtol)
AC_CHECK_FUNCS(socket, , AC_CHECK_LIB(socket, socket))
-AC_CHECK_FUNCS(gethostbyname, , AC_CHECK_LIB(nsl, gethostbyname))
+AC_CHECK_FUNCS(getaddrinfo getnameinfo)
AC_CHECK_FUNCS(strchr memcpy strstr strcmp strncmp strncpy strlen)
AC_CHECK_FUNCS(strncasecmp strcasecmp)
AC_CHECK_FUNCS(openlog syslog closelog)
AC_MSG_RESULT([$ac_system])
dnl Checks for libraries.
+# FIXME don't link all plugins against these libraries!
AC_CHECK_LIB(socket, socket)
AC_CHECK_LIB(resolv, res_search)
])
if test "x$with_libmysql" = "xyes"
then
- AC_CHECK_LIB(mysqlclient, mysql_init,, [with_libmysql="no (libmysql not found)"])
+ AC_CHECK_LIB(mysqlclient, mysql_init,
+ [
+ AC_DEFINE(HAVE_LIBMYSQLCLIENT, 1, [Define to 1 if you have the mysqlclient library (-lmysqlclient).])
+ ], [with_libmysql="no (libmysql not found)"])
fi
if test "x$with_libmysql" = "xyes"
then
- AC_CHECK_HEADERS(mysql/mysql.h,, [with_libmysql="no (mysql/mysql.h not found)"])
+ AC_CHECK_HEADERS(mysql/mysql.h,
+ [
+ AC_DEFINE(HAVE_MYSQL_MYSQL_H, 1, [Define to 1 if you have the <mysql/mysql.h> header file.])
+ ], [with_libmysql="no (mysql/mysql.h not found)"])
fi
if test "x$with_libmysql" = "xyes"
then
m4_divert_once([HELP_ENABLE], [
collectd modules:])
+AC_COLLECTD([battery], [disable], [module], [battery statistics])
AC_COLLECTD([cpu], [disable], [module], [cpu usage statistics])
AC_COLLECTD([cpufreq], [disable], [module], [system cpu frequency statistics])
AC_COLLECTD([disk], [disable], [module], [disk/partition statistics])
daemon mode . . . . $enable_daemon
Modules:
+ battery . . . . . . $enable_battery
cpu . . . . . . . . $enable_cpu
cpufreq . . . . . . $enable_cpufreq
df . . . . . . . . $enable_df