AC_DEFINE([KERNEL_AIX], 1, [True if program is to be compiled for a AIX kernel])
ac_system="AIX"
;;
+ *freebsd*)
+ AC_DEFINE([KERNEL_FREEBSD], 1, [True if program is to be compiled for a FreeBSD kernel])
+ ac_system="FreeBSD"
+ ;;
*)
ac_system="unknown"
esac
m4_divert_once([HELP_WITH], [
collectd additional packages:])
+AM_CONDITIONAL([BUILD_FREEBSD],[test "x$x$ac_system" = "xFreeBSD"])
+
AM_CONDITIONAL([BUILD_AIX],[test "x$x$ac_system" = "xAIX"])
if test "x$ac_system" = "xAIX"
# --with-libnetlink {{{
with_libnetlink_cflags=""
-with_libnetlink_libs="-lnetlink"
-AC_ARG_WITH(libnetlink, [AS_HELP_STRING([--with-libnetlink@<:@=PREFIX@:>@], [Path to libnetlink.])],
+with_libnetlink_libs="-lmnl"
+AC_ARG_WITH(libnetlink, [AS_HELP_STRING([--with-libnetlink@<:@=PREFIX@:>@], [Path to libmnl.])],
[
echo "libnetlink: withval = $withval"
if test "x$withval" = "xyes"
if test -d "$withval/include"
then
with_libnetlink_cflags="-I$withval/include"
- with_libnetlink_libs="-L$withval/lib -lnetlink"
+ with_libnetlink_libs="-L$withval/lib -lmnl"
with_libnetlink="yes"
else
AC_MSG_ERROR("no such directory: $withval/include")
#include <sys/socket.h>])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
-[[[
+[[
#include <stdio.h>
#include <sys/types.h>
#include <asm/types.h>
#include <sys/socket.h>
#include <linux/netlink.h>
#include <linux/rtnetlink.h>
-]]],
-[[[
+]],
+[[
int retval = TCA_STATS2;
return (retval);
-]]]
+]]
)],
[AC_DEFINE([HAVE_TCA_STATS2], [1], [True if the enum-member TCA_STATS2 exists])])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
-[[[
+[[
#include <stdio.h>
#include <sys/types.h>
#include <asm/types.h>
#include <sys/socket.h>
#include <linux/netlink.h>
#include <linux/rtnetlink.h>
-]]],
-[[[
+]],
+[[
int retval = TCA_STATS;
return (retval);
-]]]
+]]
)],
[AC_DEFINE([HAVE_TCA_STATS], 1, [True if the enum-member TCA_STATS exists])])
plugin_tcpconns="yes"
fi
+# FreeBSD
+
+if test "x$ac_system" = "xFreeBSD"
+then
+ plugin_zfs_arc="yes"
+fi
+
+
if test "x$with_perfstat" = "xyes"
then
plugin_cpu="yes"