aboutsummaryrefslogtreecommitdiff
path: root/dns
diff options
context:
space:
mode:
authorPhilippe Audeoud <jadawin@FreeBSD.org>2008-05-07 12:40:00 +0000
committerPhilippe Audeoud <jadawin@FreeBSD.org>2008-05-07 12:40:00 +0000
commit82f69f479b4adab79846ee70c72b1bb6ca767cbb (patch)
treeb0e21d9c74b8d46df4fff5cd4c0cd2ee8806811a /dns
parent70c61b49cc719c4cf908560962d828dd1f706078 (diff)
downloadports-82f69f479b4adab79846ee70c72b1bb6ca767cbb.tar.gz
ports-82f69f479b4adab79846ee70c72b1bb6ca767cbb.zip
Notes
Diffstat (limited to 'dns')
-rw-r--r--dns/powerdns-devel/Makefile52
-rw-r--r--dns/powerdns-devel/distinfo6
-rw-r--r--dns/powerdns-devel/files/patch-modules_gpgsqlbackend_Makefile_in10
-rw-r--r--dns/powerdns-devel/files/patch-pdns_qtype_cc15
-rw-r--r--dns/powerdns-devel/files/pdns-devel.in38
-rw-r--r--dns/powerdns-devel/files/tables-mssql_or_sybase.sql56
-rw-r--r--dns/powerdns-devel/files/tables-mysql.sql57
-rw-r--r--dns/powerdns-devel/files/tables-pgsql.sql57
-rw-r--r--dns/powerdns-devel/files/tables-sqlite.sql51
-rw-r--r--dns/powerdns-devel/pkg-plist8
10 files changed, 94 insertions, 256 deletions
diff --git a/dns/powerdns-devel/Makefile b/dns/powerdns-devel/Makefile
index 7b4da7c6df09..54bc5108813c 100644
--- a/dns/powerdns-devel/Makefile
+++ b/dns/powerdns-devel/Makefile
@@ -6,17 +6,22 @@
#
PORTNAME= powerdns
-PORTVERSION= 2.9.21
+PORTVERSION= 3.0.${SNAPSHOT}
CATEGORIES= dns ipv6
-MASTER_SITES= http://downloads.powerdns.com/releases/ \
- http://mirrors.evolva.ro/powerdns.com/releases/
-DISTNAME= pdns-${PORTVERSION}
+MASTER_SITES= http://svn.powerdns.com/snapshots/${REVISION}/
+PKGNAMESUFFIX= -devel
+DISTNAME= pdns-${PORTVERSION:S/.${SNAPSHOT}//}-svn.${SNAPSHOT}.${REVISION}
MAINTAINER= tremere@cainites.net
COMMENT= An advanced DNS server with multiple backends including SQL
BUILD_DEPENDS= bjam:${PORTSDIR}/devel/boost
+SNAPSHOT= 20080406
+REVISION= 1177
+
+CONFLICTS= powerdns-[0-2]*
+
USE_GMAKE= YES
USE_SUBMAKE= YES
USE_AUTOTOOLS= libtool:15
@@ -38,16 +43,19 @@ MAN8= pdns_control.8 pdns_server.8 zone2sql.8
SUB_FILES= pkg-message
OPTIONS= PGSQL "PostgreSQL backend" on \
+ PGSQL_LOCAL "RUN_DEPEND on PostgreSQL" off \
MYSQL "MySQL backend" off \
+ MYSQL_LOCAL "RUN_DEPEND on MySQL server" off \
SQLITE "SQLite 2 backend" off \
SQLITE3 "SQLite 3 backend" off \
OPENDBX "OpenDBX backend" off \
OPENLDAP "OpenLDAP backend" off \
+ OPENLDAP_LOCAL "RUN_DEPEND on OpenLDAP server" off \
GEO "Geo backend" off
.include <bsd.port.pre.mk>
-USE_RC_SUBR+= pdns
+USE_RC_SUBR+= pdns-devel
.if defined(WITH_GEO)
CONFIGURE_MODULES+= "geo"
@@ -80,11 +88,36 @@ CONFIGURE_ARGS+= --disable-mysql
PLIST_SUB+= WITHMYSQL="@comment "
.endif
+.if defined(WITH_OPENDBX) || defined(WITH_PGSQL)
+. if defined(WITH_PGSQL_LOCAL)
+USE_PGSQL?= YES
+RUN_DEPENDS+= postgresql-server>=0:${PORTSDIR}/databases/postgresql${PGSQL_VER}-server
+SUB_LIST+= PGSQL=postgresql
+. else
+SUB_LIST+= PGSQL=
+. endif
+.endif
+.if defined(WITH_OPENDBX) || defined(WITH_MYSQL)
+. if defined(WITH_MYSQL_LOCAL)
+USE_MYSQL?= YES
+RUN_DEPENDS+= mysql-server>=0:${PORTSDIR}/databases/mysql${MYSQL_VER}-server
+SUB_LIST+= MYSQL=mysql
+. else
+SUB_LIST+= MYSQL=
+. endif
+.endif
+
.if defined(WITH_OPENLDAP)
USE_OPENLDAP?= YES
CONFIGURE_MODULES+= "ldap"
CXXFLAGS+= -L${LOCALBASE}/lib -DLDAP_DEPRECATED=1
PLIST_SUB+= WITHOPENLDAP=""
+. if defined(WITH_OPENLDAP_LOCAL)
+RUN_DEPENDS+= openldap-server>=0:${PORTSDIR}/net/openldap${WANT_OPENLDAP_VER}-server
+SUB_LIST+= SLAPD=slapd
+. else
+SUB_LIST+= SLAPD=
+. endif
.else
PLIST_SUB+= WITHOPENLDAP="@comment "
.endif
@@ -134,10 +167,17 @@ post-install:
.endif
.if !defined(NOPORTDOCS)
${MKDIR} ${EXAMPLESDIR}
-.for i in pdns.conf tables-mssql_or_sybase.sql tables-mysql.sql tables-pgsql.sql tables-sqlite.sql
+.for i in pdns.conf
${INSTALL_DATA} ${FILESDIR}/$i ${EXAMPLESDIR}/
.endfor
.endif
+.for j in libgpgsqlbackend.so libgmysqlbackend.so libgsqlitebackend.so \
+ libgsqlite3backend.so libldapbackend.so libopendbxbackend.so \
+ libgeobackend.so libpipebackend.so
+ @if ([ -f ${PREFIX}/lib/$j ] && [ ! -f ${PREFIX}/lib/$j.0 ]); then \
+ ${LN} -sf ${PREFIX}/lib/$j ${PREFIX}/lib/$j.0; \
+ fi
+.endfor
@${CAT} ${PKGMESSAGE}
.include <bsd.port.post.mk>
diff --git a/dns/powerdns-devel/distinfo b/dns/powerdns-devel/distinfo
index 9e0cb45f04d2..9a88beda0fd4 100644
--- a/dns/powerdns-devel/distinfo
+++ b/dns/powerdns-devel/distinfo
@@ -1,3 +1,3 @@
-MD5 (pdns-2.9.21.tar.gz) = a0d650dd1489ed46b36dfcc1d73653af
-SHA256 (pdns-2.9.21.tar.gz) = 4b24db683ba2217caa1edf54545841dcdfa6fd27b66017577d8b0dd54f8e7ed5
-SIZE (pdns-2.9.21.tar.gz) = 991071
+MD5 (pdns-3.0-svn.20080406.1177.tar.gz) = af423e94344620573304aa0d52071a29
+SHA256 (pdns-3.0-svn.20080406.1177.tar.gz) = 9e3b62912dfc7fb10cf59f7215331701d9b219b9869a03020d680a41f0a12f4a
+SIZE (pdns-3.0-svn.20080406.1177.tar.gz) = 1035388
diff --git a/dns/powerdns-devel/files/patch-modules_gpgsqlbackend_Makefile_in b/dns/powerdns-devel/files/patch-modules_gpgsqlbackend_Makefile_in
index 1fb8830fff62..98a64b5a1095 100644
--- a/dns/powerdns-devel/files/patch-modules_gpgsqlbackend_Makefile_in
+++ b/dns/powerdns-devel/files/patch-modules_gpgsqlbackend_Makefile_in
@@ -1,7 +1,7 @@
---- modules/gpgsqlbackend/Makefile.in.orig Sat Jul 16 13:24:53 2005
-+++ modules/gpgsqlbackend/Makefile.in Mon Jul 18 14:22:07 2005
-@@ -203,14 +203,14 @@
- target_alias = @target_alias@
+--- modules/gpgsqlbackend/Makefile.in.org 2008-03-18 22:30:19.000000000 +0100
++++ modules/gpgsqlbackend/Makefile.in 2008-03-18 22:31:26.000000000 +0100
+@@ -213,14 +213,14 @@
+ AM_CPPFLAGS = @THREADFLAGS@
lib_LTLIBRARIES = libgpgsqlbackend.la
EXTRA_DIST = OBJECTFILES OBJECTLIBS
-INCLUDES = -I@PGSQL_incdir@
@@ -9,7 +9,7 @@
libgpgsqlbackend_la_SOURCES = gpgsqlbackend.cc gpgsqlbackend.hh \
spgsql.hh spgsql.cc
- libgpgsqlbackend_la_LDFLAGS = @PGSQL_lib@ -Wl,-Bstatic -lpq \
+ libgpgsqlbackend_la_LDFLAGS = -module -avoid-version @PGSQL_lib@ -Wl,-Bstatic -lpq \
-Wl,-Bdynamic
-libgpgsqlbackend_la_LIBADD = -lssl -lcrypt -lcrypto
diff --git a/dns/powerdns-devel/files/patch-pdns_qtype_cc b/dns/powerdns-devel/files/patch-pdns_qtype_cc
deleted file mode 100644
index 4a4c86b924ee..000000000000
--- a/dns/powerdns-devel/files/patch-pdns_qtype_cc
+++ /dev/null
@@ -1,15 +0,0 @@
-===================================================================
---- pdns/qtype.cc (revision 978)
-+++ pdns/qtype.cc (revision 1046)
-@@ -57,6 +57,11 @@
- insert("LOC",29);
- insert("SRV",33);
-+ insert("CERT", 37);
- insert("A6",38);
- insert("NAPTR",35);
-+ insert("DS", 43);
-+ insert("SSHFP", 44);
-+ insert("RRSIG", 46);
-+ insert("DNSKEY", 48);
- insert("SPF",99);
- insert("AXFR",252);
diff --git a/dns/powerdns-devel/files/pdns-devel.in b/dns/powerdns-devel/files/pdns-devel.in
new file mode 100644
index 000000000000..f53389a7fdac
--- /dev/null
+++ b/dns/powerdns-devel/files/pdns-devel.in
@@ -0,0 +1,38 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+# PROVIDE: pdns_server
+# REQUIRE: DAEMON %%MYSQL%% %%PGSQL%% %%SLAPD%%
+# KEYWORD: shutdown
+
+#
+# Add the following lines to /etc/rc.conf to enable powerdns:
+#
+#pdns_enable="YES"
+#
+# See pdns_server(8) for flags.
+#
+
+. %%RC_SUBR%%
+
+name=pdns
+rcvar=`set_rcvar`
+
+command=%%PREFIX%%/sbin/pdns_server
+
+# set defaults
+
+pdns_enable=${pdns_enable:-"NO"}
+pdns_conf=${pdns_conf:-"%%PREFIX%%/etc/pdns/pdns.conf"}
+pdns_flags=${pdns_flags:-""}
+
+load_rc_config ${name}
+
+required_files=${pdns_conf}
+
+monitor_cmd="${command} --daemon=no --guardian=no --control-console --loglevel=9"
+extra_commands="monitor"
+
+run_rc_command "$1"
diff --git a/dns/powerdns-devel/files/tables-mssql_or_sybase.sql b/dns/powerdns-devel/files/tables-mssql_or_sybase.sql
deleted file mode 100644
index 5b815186cfee..000000000000
--- a/dns/powerdns-devel/files/tables-mssql_or_sybase.sql
+++ /dev/null
@@ -1,56 +0,0 @@
-SET quoted_identifier ON;
-
-
-CREATE TABLE "domains" (
- "id" INTEGER NOT NULL IDENTITY,
- "name" VARCHAR(255) NOT NULL,
- "type" VARCHAR(6) NOT NULL,
- "master" VARCHAR(40) DEFAULT '' NOT NULL,
- "account" VARCHAR(40) DEFAULT '' NOT NULL,
- "notified_serial" INTEGER NULL,
- "last_check" INTEGER NULL,
- "status" CHAR(1) DEFAULT 'A' NOT NULL,
-CONSTRAINT "pk_domains_id"
- PRIMARY KEY ("id"),
-CONSTRAINT "unq_domains_name"
- UNIQUE ("name")
-);
-
-CREATE INDEX "idx_domains_status_type" ON "domains" ("status","type");
-
-
-
-CREATE TABLE "records" (
- "id" INTEGER NOT NULL IDENTITY,
- "domain_id" INTEGER NOT NULL,
- "name" VARCHAR(255) NOT NULL,
- "type" VARCHAR(6) NOT NULL,
- "ttl" INTEGER NULL,
- "prio" INTEGER NULL,
- "content" VARCHAR(255) NOT NULL,
- "change_date" INTEGER NULL,
-CONSTRAINT "pk_records_id"
- PRIMARY KEY ("id"),
-CONSTRAINT "fk_records_domainid"
- FOREIGN KEY ("domain_id")
- REFERENCES "domains" ("id")
-);
-
-CREATE INDEX "idx_records_name_type" ON "records" ("name","type");
-CREATE INDEX "idx_records_type" ON "records" ("type");
-
-
-
-CREATE TABLE "supermasters" (
- "ip" VARCHAR(40) NOT NULL,
- "nameserver" VARCHAR(255) NOT NULL,
- "account" VARCHAR(40) DEFAULT '' NOT NULL
-);
-
-CREATE INDEX "idx_smip_smns" ON "supermasters" ("ip","nameserver");
-
-
-
-GRANT SELECT ON "supermasters" TO "powerdns";
-GRANT ALL ON "domains" TO "powerdns";
-GRANT ALL ON "records" TO "powerdns";
diff --git a/dns/powerdns-devel/files/tables-mysql.sql b/dns/powerdns-devel/files/tables-mysql.sql
deleted file mode 100644
index c57d45c1dee1..000000000000
--- a/dns/powerdns-devel/files/tables-mysql.sql
+++ /dev/null
@@ -1,57 +0,0 @@
-SET SESSION sql_mode='ANSI';
-
-CREATE TABLE "domains" (
- "id" INTEGER NOT NULL AUTO_INCREMENT,
- "name" VARCHAR(255) NOT NULL,
- "type" VARCHAR(6) NOT NULL,
- "master" VARCHAR(40) NOT NULL DEFAULT '',
- "account" VARCHAR(40) NOT NULL DEFAULT '',
- "notified_serial" INTEGER DEFAULT NULL,
- "last_check" INTEGER DEFAULT NULL,
- "status" CHAR(1) NOT NULL DEFAULT 'A',
-CONSTRAINT "pk_domains_id"
- PRIMARY KEY ("id"),
-CONSTRAINT "unq_domains_name"
- UNIQUE ("name")
-) type=InnoDB;
-
-CREATE INDEX "idx_domains_status_type" ON "domains" ("status","type");
-
-
-
-CREATE TABLE "records" (
- "id" INTEGER NOT NULL AUTO_INCREMENT,
- "domain_id" INTEGER NOT NULL,
- "name" VARCHAR(255) NOT NULL,
- "type" VARCHAR(6) NOT NULL,
- "ttl" INTEGER DEFAULT NULL,
- "prio" INTEGER DEFAULT NULL,
- "content" VARCHAR(255) NOT NULL,
- "change_date" INTEGER DEFAULT NULL,
-CONSTRAINT "pk_records_id"
- PRIMARY KEY ("id"),
-CONSTRAINT "fk_records_domainid"
- FOREIGN KEY ("domain_id")
- REFERENCES "domains" ("id")
- ON UPDATE CASCADE
- ON DELETE CASCADE
-) type=InnoDB;
-
-CREATE INDEX "idx_records_name_type" ON "records" ("name","type");
-CREATE INDEX "idx_records_type" ON "records" ("type");
-
-
-
-CREATE TABLE "supermasters" (
- "ip" VARCHAR(40) NOT NULL,
- "nameserver" VARCHAR(255) NOT NULL,
- "account" VARCHAR(40) NOT NULL DEFAULT ''
-);
-
-CREATE INDEX "idx_smip_smns" ON "supermasters" ("ip","nameserver");
-
-
-
-GRANT SELECT ON "supermasters" TO "powerdns";
-GRANT ALL ON "domains" TO "powerdns";
-GRANT ALL ON "records" TO "powerdns";
diff --git a/dns/powerdns-devel/files/tables-pgsql.sql b/dns/powerdns-devel/files/tables-pgsql.sql
deleted file mode 100644
index 5d8afcb7032c..000000000000
--- a/dns/powerdns-devel/files/tables-pgsql.sql
+++ /dev/null
@@ -1,57 +0,0 @@
-CREATE TABLE "domains" (
- "id" SERIAL NOT NULL,
- "name" VARCHAR(255) NOT NULL,
- "type" VARCHAR(6) NOT NULL,
- "master" VARCHAR(40) NOT NULL DEFAULT '',
- "account" VARCHAR(40) NOT NULL DEFAULT '',
- "notified_serial" INTEGER DEFAULT NULL,
- "last_check" INTEGER DEFAULT NULL,
- "status" CHAR(1) NOT NULL DEFAULT 'A',
-CONSTRAINT "pk_domains_id"
- PRIMARY KEY ("id"),
-CONSTRAINT "unq_domains_name"
- UNIQUE ("name")
-);
-
-CREATE INDEX "idx_domains_status_type" ON "domains" ("status","type");
-
-
-
-CREATE TABLE "records" (
- "id" SERIAL NOT NULL,
- "domain_id" INTEGER NOT NULL,
- "name" VARCHAR(255) NOT NULL,
- "type" VARCHAR(6) NOT NULL,
- "ttl" INTEGER DEFAULT NULL,
- "prio" INTEGER DEFAULT NULL,
- "content" VARCHAR(255) NOT NULL,
- "change_date" INTEGER DEFAULT NULL,
-CONSTRAINT "pk_records_id"
- PRIMARY KEY ("id"),
-CONSTRAINT "fk_records_domainid"
- FOREIGN KEY ("domain_id")
- REFERENCES domains ("id")
- ON UPDATE CASCADE
- ON DELETE CASCADE
-);
-
-CREATE INDEX "idx_records_name_type" ON "records" ("name","type");
-CREATE INDEX "idx_records_type" ON "records" ("type");
-
-
-
-CREATE TABLE "supermasters" (
- "ip" VARCHAR(40) NOT NULL,
- "nameserver" VARCHAR(255) NOT NULL,
- "account" VARCHAR(40) NOT NULL DEFAULT ''
-);
-
-CREATE INDEX "idx_smaster_ip_ns" ON "supermasters" ("ip","nameserver");
-
-
-
-GRANT SELECT ON "supermasters" TO "powerdns";
-GRANT ALL ON "domains" TO "powerdns";
-GRANT ALL ON "domains_id_seq" TO "powerdns";
-GRANT ALL ON "records" TO "powerdns";
-GRANT ALL ON "records_id_seq" TO "powerdns";
diff --git a/dns/powerdns-devel/files/tables-sqlite.sql b/dns/powerdns-devel/files/tables-sqlite.sql
deleted file mode 100644
index 0491ac280d7f..000000000000
--- a/dns/powerdns-devel/files/tables-sqlite.sql
+++ /dev/null
@@ -1,51 +0,0 @@
-CREATE TABLE "domains" (
- "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- "name" VARCHAR(255) NOT NULL,
- "type" VARCHAR(6) NOT NULL,
- "master" VARCHAR(40) NOT NULL DEFAULT '',
- "account" VARCHAR(40) NOT NULL DEFAULT '',
- "notified_serial" INTEGER DEFAULT NULL,
- "last_check" INTEGER DEFAULT NULL,
- "status" CHAR(1) NOT NULL DEFAULT 'A',
-CONSTRAINT "unq_domains_name"
- UNIQUE ("name")
-);
-
-CREATE INDEX "idx_domains_status_type" ON "domains" ("status","type");
-
-
-
-CREATE TABLE "records" (
- "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
- "domain_id" INTEGER NOT NULL,
- "name" VARCHAR(255) NOT NULL,
- "type" VARCHAR(6) NOT NULL,
- "ttl" INTEGER DEFAULT NULL,
- "prio" INTEGER DEFAULT NULL,
- "content" VARCHAR(255) NOT NULL,
- "change_date" INTEGER DEFAULT NULL,
-CONSTRAINT "fk_records_domainid"
- FOREIGN KEY ("domain_id")
- REFERENCES "domains" ("id")
- ON UPDATE CASCADE
- ON DELETE CASCADE
-);
-
-CREATE INDEX "idx_records_name_type" ON "records" ("name","type");
-CREATE INDEX "idx_records_type" ON "records" ("type");
-
-
-
-CREATE TABLE "supermasters" (
- "ip" VARCHAR(40) NOT NULL,
- "nameserver" VARCHAR(255) NOT NULL,
- "account" VARCHAR(40) NOT NULL DEFAULT ''
-);
-
-CREATE INDEX "idx_smip_smns" ON "supermasters" ("ip","nameserver");
-
-
-
-GRANT SELECT ON "supermasters" TO "powerdns";
-GRANT ALL ON "domains" TO "powerdns";
-GRANT ALL ON "records" TO "powerdns";
diff --git a/dns/powerdns-devel/pkg-plist b/dns/powerdns-devel/pkg-plist
index f106a0c8b260..0c9e42c37fef 100644
--- a/dns/powerdns-devel/pkg-plist
+++ b/dns/powerdns-devel/pkg-plist
@@ -37,10 +37,6 @@ lib/libpipebackend.so.0
@unexec if cmp -s %D/etc/pdns/pdns.conf %D/etc/pdns/pdns.conf-dist; then rm -f %D/etc/pdns/pdns.conf; fi
etc/pdns/pdns.conf-dist
@exec [ -f %B/pdns.conf ] || cp %B/%f %B/pdns.conf
-%%PORTDOCS%%share/examples/powerdns/pdns.conf
-%%PORTDOCS%%share/examples/powerdns/tables-mssql_or_sybase.sql
-%%PORTDOCS%%share/examples/powerdns/tables-mysql.sql
-%%PORTDOCS%%share/examples/powerdns/tables-pgsql.sql
-%%PORTDOCS%%share/examples/powerdns/tables-sqlite.sql
-%%PORTDOCS%%@dirrm share/examples/powerdns
+%%PORTDOCS%%%%EXAMPLESDIR%%/pdns.conf
+%%PORTDOCS%%@dirrm %%EXAMPLESDIR%%
@dirrmtry etc/pdns