- update to 2.9.22, enable ldap.

- unbreak modules; when any module was enabled pdns_server was failing
to start up(!). Brad traced this to a LINK_SPEC problem and came up
with the workaround in patch-configure_in, thanks very much!

- set SHARED_ONLY and merge PFRAG.shared into PLISTs; PowerDNS itself
can work static-only, but you need to compile-in the relevant modules,
which doesn't mix well with MULTI_PACKAGES.

mysql backend is tested; other backends not yet, but this is a big
improvement on what's there at the moment.
This commit is contained in:
sthen 2009-06-23 22:59:57 +00:00
parent 8c2cbb8b06
commit 4d27560758
19 changed files with 101 additions and 67 deletions

View File

@ -1,28 +1,26 @@
# $OpenBSD: Makefile,v 1.9 2009/06/18 20:08:25 naddy Exp $
# $OpenBSD: Makefile,v 1.10 2009/06/23 22:59:57 sthen Exp $
SHARED_ONLY= Yes
COMMENT-main= modern authoritative nameserver
COMMENT-mysql= mysql database access module for powerdns
COMMENT-pgsql= pgsql database access module for powerdns
COMMENT-sqlite= sqlite database access module for powerdns
COMMENT-sqlite3= sqlite3 database access module for powerdns
COMMENT-ldap= ldap module for powerdns
V= 2.9.21.2
V= 2.9.22
DISTNAME= pdns-${V}
PKGNAME= powerdns-${V}
PKGNAME-main= powerdns-${V}p3
PKGNAME-mysql= powerdns-mysql-${V}p2
PKGNAME-pgsql= powerdns-pgsql-${V}p2
PKGNAME-sqlite= powerdns-sqlite-${V}p2
PKGNAME-sqlite3= powerdns-sqlite3-${V}p2
PKGNAME-main= powerdns-${V}
PKGNAME-mysql= powerdns-mysql-${V}
PKGNAME-pgsql= powerdns-pgsql-${V}
PKGNAME-sqlite= powerdns-sqlite-${V}
PKGNAME-sqlite3= powerdns-sqlite3-${V}
PKGNAME-ldap= powerdns-ldap-${V}
CATEGORIES= net
HOMEPAGE= http://www.powerdns.com/
SHARED_LIBS= geobackend 0.0 \
gmysqlbackend 0.0 \
gpgsqlbackend 0.0 \
gsqlite3backend 0.0 \
gsqlitebackend 0.0
MULTI_PACKAGES= -main
# GPLv2
@ -65,6 +63,7 @@ CONFIGURE_ARGS+= --with-pgsql=${LOCALBASE} \
--with-pgsql-includes=${LOCALBASE}/include/postgresql
LIB_DEPENDS-pgsql= pq.>=2::databases/postgresql,-main
RUN_DEPENDS-pgsql= :${FULLPKGNAME-main}:net/powerdns
WANTLIB-pgsql= crypto ssl z
BACKENDS+= gpgsql
.endif
@ -94,6 +93,19 @@ WANTLIB-sqlite3+= z
BACKENDS+= gsqlite3
.endif
# LDAP
.if ${FLAVOR:L:Mno_ldap}
CONFIGURE_ARGS+= --without-ldap
.else
MULTI_PACKAGES+= -ldap
LIB_DEPENDS-ldap= lber,ldap_r::databases/openldap
RUN_DEPENDS-ldap= :${FULLPKGNAME-main}:net/powerdns
CONFIGURE_ARGS+= --with-ldap=${LOCALBASE} \
--with-ldap-includes=${LOCALBASE}/include
WANTLIB-ldap+= asn1 com_err crypto gssapi krb5 sasl2 ssl z
BACKENDS+= ldap
.endif
USE_LIBTOOL= Yes
BUILD_DEPENDS+= ${MODGNU_AUTOCONF_DEPENDS}
@ -103,7 +115,9 @@ AUTOCONF_VERSION= 2.61
CONFIGURE_STYLE= gnu autoconf
CONFIGURE_ENV+= CPPFLAGS="-I${LOCALBASE}/include" \
LDFLAGS="-L${LOCALBASE}/lib"
CONFIGURE_ARGS+= --with-modules="geo" \
CONFIGURE_ARGS+= --enable-shared=no \
--libdir="${PREFIX}/lib/powerdns" \
--with-modules="geo" \
--with-dynmodules="${BACKENDS}" \
--disable-recursor # OpenBSD lacks ucontext.h, see PR 5099
@ -122,4 +136,4 @@ post-install:
.include <bsd.port.mk>
CONFIGURE_ARGS+= --sysconfdir="${SYSCONFDIR}/pdns"
CONFIGURE_ARGS+= --sysconfdir="${SYSCONFDIR}/pdns" \

View File

@ -1,5 +1,5 @@
MD5 (pdns-2.9.21.2.tar.gz) = KqecHRIKBxKYNA7S1OAhZQ==
RMD160 (pdns-2.9.21.2.tar.gz) = 4ooxxoFqOCUCEkcmpf6axm3S35Q=
SHA1 (pdns-2.9.21.2.tar.gz) = kIg2EHHdtsK9MuuQxsFmc26KIp0=
SHA256 (pdns-2.9.21.2.tar.gz) = BMfqACS5bscO1zlQsjlNP0XwPVvCJEjGjgcwIrnG6Ak=
SIZE (pdns-2.9.21.2.tar.gz) = 1008111
MD5 (pdns-2.9.22.tar.gz) = im/4QnM6yohVd+tU6YOh/w==
RMD160 (pdns-2.9.22.tar.gz) = vpv/PtrAqXAOr4rDDHe/yDNrfZI=
SHA1 (pdns-2.9.22.tar.gz) = LAiIyCUimcWhfcae7CiekMfo8/8=
SHA256 (pdns-2.9.22.tar.gz) = fAPaAcLL2LvolxgLw71Qyoz6pjralNxrKfd0W4LhdSU=
SIZE (pdns-2.9.22.tar.gz) = 1072257

View File

@ -0,0 +1,17 @@
$OpenBSD: patch-configure_in,v 1.1 2009/06/23 22:59:57 sthen Exp $
workaround OpenBSD gcc LINK_SPEC problem (not obeying -rdynamic)
--- configure.in.orig Tue Jun 23 05:50:24 2009
+++ configure.in Tue Jun 23 05:52:40 2009
@@ -89,8 +89,8 @@ linux*)
;;
openbsd*)
AC_DEFINE(HAVE_IPV6,1,[If the host operating system understands IPv6])
- DYNLINKFLAGS="-rdynamic"
- LDFLAGS="-lc_r $LDFLAGS"
+ DYNLINKFLAGS="-Wl,-export-dynamic"
+ LDFLAGS="-pthread $LDFLAGS"
CXXFLAGS="-pthread $CXXFLAGS"
;;
*)

View File

@ -1,11 +1,11 @@
$OpenBSD: patch-modules_gpgsqlbackend_Makefile_in,v 1.1 2008/12/16 10:30:27 jasper Exp $
$OpenBSD: patch-modules_gpgsqlbackend_Makefile_in,v 1.2 2009/06/23 22:59:57 sthen Exp $
libcrypt doesn't exist on OpenBSD.
--- modules/gpgsqlbackend/Makefile.in.orig Wed Dec 10 19:15:32 2008
+++ modules/gpgsqlbackend/Makefile.in Wed Dec 10 19:15:35 2008
@@ -222,7 +222,7 @@ libgpgsqlbackend_la_SOURCES = gpgsqlbackend.cc gpgsqlb
libgpgsqlbackend_la_LDFLAGS = @PGSQL_lib@ -Wl,-Bstatic -lpq \
--- modules/gpgsqlbackend/Makefile.in.orig Sun Jan 25 20:24:46 2009
+++ modules/gpgsqlbackend/Makefile.in Mon Jun 22 23:52:31 2009
@@ -224,7 +224,7 @@ libgpgsqlbackend_la_SOURCES = gpgsqlbackend.cc gpgsqlb
libgpgsqlbackend_la_LDFLAGS = -module -avoid-version @PGSQL_lib@ -Wl,-Bstatic -lpq \
-Wl,-Bdynamic
-libgpgsqlbackend_la_LIBADD = -lssl -lcrypt -lcrypto

View File

@ -1,11 +1,11 @@
$OpenBSD: patch-modules_gpgsqlbackend_OBJECTLIBS,v 1.2 2008/12/16 10:30:27 jasper Exp $
$OpenBSD: patch-modules_gpgsqlbackend_OBJECTLIBS,v 1.3 2009/06/23 22:59:57 sthen Exp $
These libraries don't exist on OpenBSD.
libcrypt doesn't exist on OpenBSD.
--- modules/gpgsqlbackend/OBJECTLIBS.orig Sun Aug 3 14:47:25 2008
+++ modules/gpgsqlbackend/OBJECTLIBS Sun Aug 3 14:47:30 2008
--- modules/gpgsqlbackend/OBJECTLIBS.orig Wed Nov 19 08:31:09 2008
+++ modules/gpgsqlbackend/OBJECTLIBS Mon Jun 22 23:52:28 2009
@@ -1,3 +1,3 @@
--lpq -lssl -lcrypto -lcrypt -lresolv -lnsl
--lpq -lssl -lcrypto -lcrypt
+-lpq -lssl -lcrypto

View File

@ -1,10 +1,10 @@
$OpenBSD: patch-pdns_Makefile_in,v 1.2 2008/12/16 10:30:27 jasper Exp $
$OpenBSD: patch-pdns_Makefile_in,v 1.3 2009/06/23 22:59:57 sthen Exp $
Remove target that we take care of in post-install.
--- pdns/Makefile.in.orig Mon Sep 22 12:46:55 2008
+++ pdns/Makefile.in Mon Sep 22 12:50:20 2008
@@ -1042,8 +1042,7 @@ info-am:
--- pdns/Makefile.in.orig Sun Jan 25 20:24:49 2009
+++ pdns/Makefile.in Mon Jun 22 23:52:31 2009
@@ -1152,8 +1152,7 @@ info-am:
install-data-am:

View File

@ -1,10 +1,10 @@
$OpenBSD: patch-pdns_dns_hh,v 1.2 2008/12/16 10:30:27 jasper Exp $
$OpenBSD: patch-pdns_dns_hh,v 1.3 2009/06/23 22:59:57 sthen Exp $
Missing header.
--- pdns/dns.hh.orig Sat Apr 21 23:56:36 2007
+++ pdns/dns.hh Sun Aug 3 11:52:57 2008
@@ -173,6 +173,8 @@ typedef enum {
--- pdns/dns.hh.orig Sat Nov 15 20:05:43 2008
+++ pdns/dns.hh Mon Jun 22 23:52:28 2009
@@ -177,6 +177,8 @@ enum {
#include <machine/endian.h>
#elif __linux__
# include <endian.h>

View File

@ -0,0 +1,7 @@
The PowerDNS daemon is a versatile nameserver which supports
a large number of backends. These backends can either be plain
zonefiles or be more dynamic in nature. Additionally, through
use of clever programming techniques, PowerDNS offers very high
domain resolution performance.
This package contains the LDAP backend.

View File

@ -1,2 +0,0 @@
@comment $OpenBSD: PFRAG.shared-main,v 1.1.1.1 2008/10/02 18:40:41 jasper Exp $
@lib lib/libgeobackend.so.${LIBgeobackend_VERSION}

View File

@ -1,2 +0,0 @@
@comment $OpenBSD: PFRAG.shared-mysql,v 1.1.1.1 2008/10/02 18:40:41 jasper Exp $
@lib lib/libgmysqlbackend.so.${LIBgmysqlbackend_VERSION}

View File

@ -1,2 +0,0 @@
@comment $OpenBSD: PFRAG.shared-pgsql,v 1.1.1.1 2008/10/02 18:40:41 jasper Exp $
@lib lib/libgpgsqlbackend.so.${LIBgpgsqlbackend_VERSION}

View File

@ -1,2 +0,0 @@
@comment $OpenBSD: PFRAG.shared-sqlite,v 1.1.1.1 2008/10/02 18:40:41 jasper Exp $
@lib lib/libgsqlitebackend.so.${LIBgsqlitebackend_VERSION}

View File

@ -1,2 +0,0 @@
@comment $OpenBSD: PFRAG.shared-sqlite3,v 1.1.1.1 2008/10/02 18:40:41 jasper Exp $
@lib lib/libgsqlite3backend.so.${LIBgsqlite3backend_VERSION}

View File

@ -0,0 +1,4 @@
@comment $OpenBSD: PLIST-ldap,v 1.1 2009/06/23 22:59:57 sthen Exp $
@comment lib/powerdns/libldapbackend.a
@comment lib/powerdns/libldapbackend.la
lib/powerdns/libldapbackend.so

View File

@ -1,12 +1,13 @@
@comment $OpenBSD: PLIST-main,v 1.2 2008/10/07 21:02:53 jasper Exp $
@comment $OpenBSD: PLIST-main,v 1.3 2009/06/23 22:59:57 sthen Exp $
@newgroup _powerdns:609
@newuser _powerdns:609:_powerdns:daemon:Proxy DNS Server:/nonexistent:/sbin/nologin
%%SHARED%%
@bin bin/pdns_control
@bin bin/zone2ldap
@bin bin/zone2sql
lib/libgeobackend.a
lib/libgeobackend.la
lib/powerdns/
@comment lib/powerdns/libgeobackend.a
@comment lib/powerdns/libgeobackend.la
lib/powerdns/libgeobackend.so
@man man/man8/pdns_control.8
@man man/man8/pdns_server.8
@man man/man8/zone2sql.8

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST-mysql,v 1.1.1.1 2008/10/02 18:40:41 jasper Exp $
%%SHARED%%
lib/libgmysqlbackend.a
lib/libgmysqlbackend.la
@comment $OpenBSD: PLIST-mysql,v 1.2 2009/06/23 22:59:57 sthen Exp $
@comment lib/powerdns/libgmysqlbackend.a
@comment lib/powerdns/libgmysqlbackend.la
lib/powerdns/libgmysqlbackend.so

View File

@ -1,3 +1,4 @@
@comment $OpenBSD: PLIST-pgsql,v 1.1.1.1 2008/10/02 18:40:41 jasper Exp $
lib/libgpgsqlbackend.a
lib/libgpgsqlbackend.la
@comment $OpenBSD: PLIST-pgsql,v 1.2 2009/06/23 22:59:57 sthen Exp $
@comment lib/powerdns/libgpgsqlbackend.a
@comment lib/powerdns/libgpgsqlbackend.la
lib/powerdns/libgpgsqlbackend.so

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST-sqlite,v 1.1.1.1 2008/10/02 18:40:41 jasper Exp $
%%SHARED%%
lib/libgsqlitebackend.a
lib/libgsqlitebackend.la
@comment $OpenBSD: PLIST-sqlite,v 1.2 2009/06/23 22:59:57 sthen Exp $
@comment lib/powerdns/libgsqlitebackend.a
@comment lib/powerdns/libgsqlitebackend.la
lib/powerdns/libgsqlitebackend.so

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST-sqlite3,v 1.1.1.1 2008/10/02 18:40:41 jasper Exp $
%%SHARED%%
lib/libgsqlite3backend.a
lib/libgsqlite3backend.la
@comment $OpenBSD: PLIST-sqlite3,v 1.2 2009/06/23 22:59:57 sthen Exp $
@comment lib/powerdns/libgsqlite3backend.a
@comment lib/powerdns/libgsqlite3backend.la
lib/powerdns/libgsqlite3backend.so