aboutsummaryrefslogtreecommitdiff
path: root/dns/powerdns-recursor
diff options
context:
space:
mode:
authorEmanuel Haupt <ehaupt@FreeBSD.org>2006-11-15 23:59:16 +0000
committerEmanuel Haupt <ehaupt@FreeBSD.org>2006-11-15 23:59:16 +0000
commit88ba353662f83da1b3f4e25d796bdd23191c856c (patch)
treef1366f53022185cf922c52346b25fc383e5bb1d8 /dns/powerdns-recursor
parent311cb2199dd1aa9a5a090e11ed6cf1c1f743a16b (diff)
downloadports-88ba353662f83da1b3f4e25d796bdd23191c856c.tar.gz
ports-88ba353662f83da1b3f4e25d796bdd23191c856c.zip
Notes
Diffstat (limited to 'dns/powerdns-recursor')
-rw-r--r--dns/powerdns-recursor/Makefile59
-rw-r--r--dns/powerdns-recursor/distinfo3
-rw-r--r--dns/powerdns-recursor/files/patch-makefile29
-rw-r--r--dns/powerdns-recursor/files/patch-manpages58
-rw-r--r--dns/powerdns-recursor/files/pdns-recursor.in35
-rw-r--r--dns/powerdns-recursor/files/pkg-message.in11
-rw-r--r--dns/powerdns-recursor/pkg-descr4
-rw-r--r--dns/powerdns-recursor/pkg-plist6
8 files changed, 205 insertions, 0 deletions
diff --git a/dns/powerdns-recursor/Makefile b/dns/powerdns-recursor/Makefile
new file mode 100644
index 000000000000..fda7c27a9c79
--- /dev/null
+++ b/dns/powerdns-recursor/Makefile
@@ -0,0 +1,59 @@
+# New ports collection makefile for: powerdns-recursor
+# Date Created: 14.Nov 2006
+# Whom: sten@blinkenlights.nl
+#
+# $FreeBSD$
+#
+
+PORTNAME= powerdns-recursor
+PORTVERSION= 3.1.4
+CATEGORIES= dns ipv6
+MASTER_SITES= http://downloads.powerdns.com/releases/ \
+ http://mirrors.evolva.ro/powerdns.com/releases/
+DISTNAME= pdns-recursor-${PORTVERSION}
+
+MAINTAINER= sten@blinkenlights.nl
+COMMENT= An advanced DNS recursor
+
+BUILD_DEPENDS= bjam:${PORTSDIR}/devel/boost
+
+USE_BZIP2= yes
+USE_GMAKE= yes
+
+CXXFLAGS+= -I${LOCALBASE}/include
+LDFLAGS+= -L${LOCALBASE}/lib
+
+MAKE_ENV+= CXX="${CXX}" CC="${CC}"
+
+MAN8= rec_control.8 pdns_recursor.8
+SUB_FILES= pkg-message
+
+.include <bsd.port.pre.mk>
+
+USE_RC_SUBR+= pdns-recursor
+
+.if exists(/usr/include/ucontext.h) && ${OSVERSION} >= 500000
+UCONTEXT!= ${AWK} '/setcontext/ { print "YES" }' \
+ /usr/include/ucontext.h
+.if ${UCONTEXT} == ""
+BROKEN= requires setcontext()
+.endif
+.endif
+
+post-patch:
+ @${REINPLACE_CMD} -e 's;SBINDIR=/usr/sbin/;SBINDIR=${PREFIX}/sbin/;' \
+ -e 's;BINDIR=/usr/bin/;BINDIR=${PREFIX}/bin/;' \
+ -e 's;CONFIGDIR="/etc/powerdns/";CONFIGDIR=${PREFIX}/etc/pdns/;' \
+ ${WRKSRC}/Makefile
+ @${REINPLACE_CMD} -e 's;"/etc/powerdns/";"${PREFIX}/etc/powerdns/";' \
+ ${WRKSRC}/config.h
+
+post-install:
+.if !exists(${PREFIX}/etc/pdns/recursor.conf)
+ ${INSTALL_DATA} ${PREFIX}/etc/pdns/recursor.conf-dist \
+ ${PREFIX}/etc/pdns/recursor.conf
+.endif
+ @${INSTALL_MAN} ${WRKSRC}/*.8 ${PREFIX}/man/man8/
+ @${CAT} ${PKGMESSAGE}
+
+.include <bsd.port.post.mk>
diff --git a/dns/powerdns-recursor/distinfo b/dns/powerdns-recursor/distinfo
new file mode 100644
index 000000000000..0e4f55a72949
--- /dev/null
+++ b/dns/powerdns-recursor/distinfo
@@ -0,0 +1,3 @@
+MD5 (pdns-recursor-3.1.4.tar.bz2) = 439a10639f53def0ba47c0851e4a2671
+SHA256 (pdns-recursor-3.1.4.tar.bz2) = 9975ec73e311bda4c22f302f18f4ed4fe701d63bce3155f300ccc561d5b0cc39
+SIZE (pdns-recursor-3.1.4.tar.bz2) = 139191
diff --git a/dns/powerdns-recursor/files/patch-makefile b/dns/powerdns-recursor/files/patch-makefile
new file mode 100644
index 000000000000..1bc22058de97
--- /dev/null
+++ b/dns/powerdns-recursor/files/patch-makefile
@@ -0,0 +1,29 @@
+--- Makefile.orig Tue Nov 14 13:26:24 2006
++++ Makefile Tue Nov 14 13:26:51 2006
+@@ -2,7 +2,6 @@
+ SBINDIR=/usr/sbin/
+ BINDIR=/usr/bin/
+ CONFIGDIR="/etc/powerdns/"
+-OPTFLAGS?=-O3
+ CXXFLAGS:= $(CXXFLAGS) -Wall $(OPTFLAGS) $(PROFILEFLAGS)
+ CFLAGS:=$(CFLAGS) -Wall $(OPTFLAGS) $(PROFILEFLAGS)
+ LINKCC=$(CXX)
+@@ -52,16 +52,14 @@
+ fi
+
+ install: all
+- -mkdir -p $(DESTDIR)/$(SBINDIR)
+ mv pdns_recursor $(DESTDIR)/$(SBINDIR)
+ strip $(DESTDIR)/$(SBINDIR)/pdns_recursor
+- mkdir -p $(DESTDIR)/$(BINDIR)
+ mv rec_control $(DESTDIR)/$(BINDIR)
+ strip $(DESTDIR)/$(BINDIR)/rec_control
+ -mkdir -p $(DESTDIR)/$(CONFIGDIR)
+ $(DESTDIR)/$(SBINDIR)/pdns_recursor --config > $(DESTDIR)/$(CONFIGDIR)/recursor.conf-dist
+- -mkdir -p $(DESTDIR)/usr/share/man/man1
+- cp pdns_recursor.1 rec_control.1 $(DESTDIR)/usr/share/man/man1
++ mv pdns_recursor.1 pdns_recursor.8
++ mv rec_control.1 rec_control.8
+ $(OS_SPECIFIC_INSTALL)
+
+ clean:
diff --git a/dns/powerdns-recursor/files/patch-manpages b/dns/powerdns-recursor/files/patch-manpages
new file mode 100644
index 000000000000..835e237e76ea
--- /dev/null
+++ b/dns/powerdns-recursor/files/patch-manpages
@@ -0,0 +1,58 @@
+--- rec_control.1.orig Tue Nov 14 13:47:26 2006
++++ rec_control.1 Tue Nov 14 13:47:55 2006
+@@ -17,7 +17,7 @@
+ .el .ne 3
+ .IP "\\$1" \\$2
+ ..
+-.TH "REC_CONTROL" 1 "" "" ""
++.TH "REC_CONTROL" 8 "" "" ""
+ .SH NAME
+ rec_control \- control pdns_recursor
+ .SH "SYNOPSIS"
+@@ -28,7 +28,7 @@
+ .SH "DESCRIPTION"
+
+
+-rec_control(1) allows the operator to control a running instance of the pdns_recursor\&.
++rec_control(8) allows the operator to control a running instance of the pdns_recursor\&.
+
+
+ The commands that can be passed to the recursor are described on http://doc\&.powerdns\&.com/rec\-control\&.html
+@@ -111,7 +111,7 @@
+ .SH "SEE ALSO"
+
+
+-pdns_recursor(1)
++pdns_recursor(8)
+
+ .SH "COPYING"
+
+--- pdns_recursor.1.orig Tue Nov 14 13:48:13 2006
++++ pdns_recursor.1 Tue Nov 14 13:48:44 2006
+@@ -17,7 +17,7 @@
+ .el .ne 3
+ .IP "\\$1" \\$2
+ ..
+-.TH "PDNS_RECURSOR" 1 "" "" ""
++.TH "PDNS_RECURSOR" 8 "" "" ""
+ .SH NAME
+ pdns_recursor \- high-performance, simple and secure recursing nameserver
+ .SH "SYNOPSIS"
+@@ -28,7 +28,7 @@
+ .SH "DESCRIPTION"
+
+
+-pdns_recursor(1) is a high performance, simple and secure recursing nameserver\&. It currently powers over two million internet connections\&.
++pdns_recursor(8) is a high performance, simple and secure recursing nameserver\&. It currently powers over two million internet connections\&.
+
+
+ The recursor is configured via a configuration file, but each item in that file can be overridden on the command line\&.
+@@ -211,7 +211,7 @@
+ .SH "SEE ALSO"
+
+
+-rec_control(1)
++rec_control(8)
+
+ .SH "COPYING"
+
diff --git a/dns/powerdns-recursor/files/pdns-recursor.in b/dns/powerdns-recursor/files/pdns-recursor.in
new file mode 100644
index 000000000000..4056deaf7961
--- /dev/null
+++ b/dns/powerdns-recursor/files/pdns-recursor.in
@@ -0,0 +1,35 @@
+#!/bin/sh
+#
+# $$
+#
+
+# PROVIDE: pdns_recursor
+# REQUIRE: DAEMON
+# KEYWORD: shutdown
+
+#
+# Add the following lines to /etc/rc.conf to enable pdns_recursor:
+#
+#pdns_recursor_enable="YES"
+#
+# See pdns_recursor(8) for flags.
+#
+
+. %%RC_SUBR%%
+
+name=pdns_recursor
+rcvar=`set_rcvar`
+
+command=%%PREFIX%%/sbin/pdns_recursor
+
+# set defaults
+
+pdns_recursor_enable=${pdns_recursor_enable:-"NO"}
+pdns_recursor_conf=${pdns_recursor_conf:-"%%PREFIX%%/etc/pdns/recursor.conf"}
+pdns_recursor_flags=${pdns_recursor_flags:-""}
+
+load_rc_config ${name}
+
+required_files=${pdns_recursor_conf}
+
+run_rc_command "$1"
diff --git a/dns/powerdns-recursor/files/pkg-message.in b/dns/powerdns-recursor/files/pkg-message.in
new file mode 100644
index 000000000000..a5480fd56ad2
--- /dev/null
+++ b/dns/powerdns-recursor/files/pkg-message.in
@@ -0,0 +1,11 @@
+
+*******************************************************************
+ If you want to use the powerdns recursor,
+ you need the following line in /etc/rc.conf(.local)
+
+ pdns_recursor_enable="YES"
+
+ Configuration templates are available in %%PREFIX%%/etc/pdns
+ as recursor.conf-dist.
+*******************************************************************
+
diff --git a/dns/powerdns-recursor/pkg-descr b/dns/powerdns-recursor/pkg-descr
new file mode 100644
index 000000000000..00d927a78ca7
--- /dev/null
+++ b/dns/powerdns-recursor/pkg-descr
@@ -0,0 +1,4 @@
+powerdns recursor is a high performance, simple and secure recursing
+nameserver. It currently powers over two million internet connections.
+
+WWW: http://www.powerdns.com
diff --git a/dns/powerdns-recursor/pkg-plist b/dns/powerdns-recursor/pkg-plist
new file mode 100644
index 000000000000..f07434a5d4f3
--- /dev/null
+++ b/dns/powerdns-recursor/pkg-plist
@@ -0,0 +1,6 @@
+@unexec if cmp -s %D/etc/pdns/recursor.conf %D/etc/pdns/recursor.conf-dist; then rm -f %D/etc/pdns/recursor.conf; fi
+etc/pdns/recursor.conf-dist
+@exec [ -f %B/recursor.conf ] || cp %B/%f %B/recursor.conf
+bin/rec_control
+sbin/pdns_recursor
+@dirrmtry etc/pdns