aboutsummaryrefslogtreecommitdiff
path: root/net-mgmt
diff options
context:
space:
mode:
authorDmitry Sivachenko <demon@FreeBSD.org>2013-12-15 15:13:13 +0000
committerDmitry Sivachenko <demon@FreeBSD.org>2013-12-15 15:13:13 +0000
commitc9d936d7aabdde821bb361e8a11da91eeaabd893 (patch)
tree8c36916cc3d61b003bfdbf66c0bbc642e8c138f0 /net-mgmt
parent6e427692269bc8293538343de522e7917ccf1b5a (diff)
Notes
Diffstat (limited to 'net-mgmt')
-rw-r--r--net-mgmt/nagios-plugins/Makefile8
-rw-r--r--net-mgmt/nagios-plugins/files/extra-patch-dig-to-drill.diff11
-rw-r--r--net-mgmt/nagios-plugins/pkg-plist2
3 files changed, 20 insertions, 1 deletions
diff --git a/net-mgmt/nagios-plugins/Makefile b/net-mgmt/nagios-plugins/Makefile
index 1e934b0f98ae..5dc0f753294e 100644
--- a/net-mgmt/nagios-plugins/Makefile
+++ b/net-mgmt/nagios-plugins/Makefile
@@ -148,6 +148,14 @@ CONFIGURE_ARGS+= --without-dbi
PLIST_SUB+= SUB_DBI="@comment "
.endif
+.if ${OSVERSION} > 1000055
+EXTRA_PATCHES+= ${FILESDIR}/extra-patch-dig-to-drill.diff
+CONFIGURE_ARGS+=--with-dig-command=/usr/bin/drill
+PLIST_SUB+= SUB_DNS="@comment "
+.else
+PLIST_SUB+= SUB_DNS=""
+.endif
+
post-patch:
.for file in check_by_ssh.c check_disk.c check_http.c check_mrtgtraf.c \
check_nagios.c check_ntp.c check_ntp_peer.c check_ntp_time.c \
diff --git a/net-mgmt/nagios-plugins/files/extra-patch-dig-to-drill.diff b/net-mgmt/nagios-plugins/files/extra-patch-dig-to-drill.diff
new file mode 100644
index 000000000000..be1b8ee89e98
--- /dev/null
+++ b/net-mgmt/nagios-plugins/files/extra-patch-dig-to-drill.diff
@@ -0,0 +1,11 @@
+--- plugins/check_dig.c.orig 2013-10-02 19:22:21.000000000 +0400
++++ plugins/check_dig.c 2013-12-15 16:55:26.000000000 +0400
+@@ -88,7 +88,7 @@ main (int argc, char **argv)
+ usage_va(_("Could not parse arguments"));
+
+ /* get the command to run */
+- xasprintf (&command_line, "%s @%s -p %d %s -t %s %s %s",
++ xasprintf (&command_line, "%s @%s -p %d %s %s %s %s",
+ PATH_TO_DIG, dns_server, server_port, query_address, record_type, dig_args, query_transport);
+
+ alarm (timeout_interval);
diff --git a/net-mgmt/nagios-plugins/pkg-plist b/net-mgmt/nagios-plugins/pkg-plist
index 1bc7b924f15f..a16611407bf1 100644
--- a/net-mgmt/nagios-plugins/pkg-plist
+++ b/net-mgmt/nagios-plugins/pkg-plist
@@ -8,7 +8,7 @@ libexec/nagios/check_dhcp
libexec/nagios/check_dig
libexec/nagios/check_disk
libexec/nagios/check_disk_smb
-libexec/nagios/check_dns
+%%SUB_DNS%%libexec/nagios/check_dns
libexec/nagios/check_dummy
libexec/nagios/check_file_age
libexec/nagios/check_flexlm