ports/98895: [PATCH] net-mgmt/nagios-plugins: Fix check_dns error on 4.X

chinsan chinsan.tw at gmail.com
Tue Jun 13 06:30:24 UTC 2006

>Number:         98895
>Category:       ports
>Synopsis:       [PATCH] net-mgmt/nagios-plugins: Fix check_dns error on 4.X
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Jun 13 06:30:20 GMT 2006
>Originator:     chinsan
>Release:        FreeBSD 6.1-STABLE i386
FreeBSD Taiwan
System: FreeBSD chinsan2.twbbs.org 6.1-STABLE FreeBSD 6.1-STABLE #1: Fri Jun  2 16:44:35 CST
- Fix check_dns error on 4.X
  Since FreeBSd 5.x, the build-in nslookup has been MFCed from BIND 9 and related bits.
  and retire the BIND 8 sources.

  So, we still need a hyphen (-) as the prefix of the first argument on 4.X,
  This workaround patch can fix this problem.

Port maintainer (jarrod at netleader.com.au) is cc'd.

Generated with FreeBSD Port Tools 0.77

FreeBSD 4.X box:

chinsan at saint </usr/local/etc/nagios> nslookup bbs.webamp.cc
*** Can't find server name for address No information
*** Default servers are not available

chinsan at saint </usr/local/etc/nagios> nslookup -bbs.webamp.cc
*** Invalid option: bbs.webamp.cc
Server:  dns3.giga.net.tw

Name:    u29-178.u203-187.giga.net.tw


--- nagios-plugins-1.4.3_1,1.patch begins here ---
diff -ruN --exclude=CVS /usr/ports/net-mgmt/nagios-plugins/Makefile /usr/home/chinsan/project/nagios-plugins/Makefile
--- /usr/ports/net-mgmt/nagios-plugins/Makefile	Tue May 16 23:46:15 2006
+++ /usr/home/chinsan/project/nagios-plugins/Makefile	Tue Jun 13 14:17:13 2006
@@ -7,6 +7,7 @@
 PORTNAME=	nagios-plugins
 CATEGORIES=	net-mgmt
@@ -134,5 +135,8 @@
 	check_time.c check_users.c utils.c
 	@${REINPLACE_CMD} -e 's|setlocale (LC_ALL, "");|setlocale (LC_ALL, ""); setlocale(LC_NUMERIC, "C");|g' ${WRKSRC}/plugins/${file}
+.if ${OSVERSION} < 500000
+	@${REINPLACE_CMD} -e 's,%s %s %s,%s -%s %s,' ${WRKSRC}/plugins/check_dns.c
 .include <bsd.port.post.mk>
--- nagios-plugins-1.4.3_1,1.patch ends here ---


More information about the freebsd-ports-bugs mailing list