From 43bc16aa5e2b7a714e726d202232b02174b299b2 Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Thu, 13 Sep 2012 17:56:13 +0200 Subject: [PATCH] configure: Activate the PF plugin when net/pfvar.h is available. Apparently PF has been or is being ported to FreeBSD, so simply checking the OS name is not the best of ideas. --- configure.in | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/configure.in b/configure.in index 33ecca7c..c5544c12 100644 --- a/configure.in +++ b/configure.in @@ -535,6 +535,9 @@ AC_CHECK_HEADERS(netinet/if_ether.h, [], [], AC_CHECK_HEADERS(netinet/ip_compat.h) +have_net_pfvar_h="no" +AC_CHECK_HEADERS(net/pfvar.h, [have_net_pfvar_h="yes"]) + # For the multimeter plugin have_termios_h="no" AC_CHECK_HEADERS(termios.h, [have_termios_h="yes"]) @@ -4544,7 +4547,6 @@ fi if test "x$ac_system" = "xOpenBSD" then plugin_tcpconns="yes" - plugin_pf="yes" fi # Mac OS X devices @@ -4844,7 +4846,7 @@ AC_PLUGIN([onewire], [$with_libowcapi], [OneWire sensor statistics]) AC_PLUGIN([openvpn], [yes], [OpenVPN client statistics]) AC_PLUGIN([oracle], [$with_oracle], [Oracle plugin]) AC_PLUGIN([perl], [$plugin_perl], [Embed a Perl interpreter]) -AC_PLUGIN([pf], [$plugin_pf], [OpenBSD packet filter (PF) statistics]) +AC_PLUGIN([pf], [$have_net_pfvar_h], [BSD packet filter (PF) statistics]) # FIXME: Check for libevent, too. AC_PLUGIN([pinba], [$have_protoc_c], [Pinba statistics]) AC_PLUGIN([ping], [$with_liboping], [Network latency statistics]) -- 2.11.0