summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKonstantin V. Arkhipov <voxus@gentoo.org>2005-06-23 17:37:44 +0000
committerKonstantin V. Arkhipov <voxus@gentoo.org>2005-06-23 17:37:44 +0000
commit7355f712db61f18bfc0fc29f0f8d33be25cc49e0 (patch)
tree918439ce324e8a665a7900a1a93d577c5618bdad /net-dns/bind
parentSATA bridge lockup fix. Add support for BCM5785. Add support for pdc20619. Re... (diff)
downloadhistorical-7355f712db61f18bfc0fc29f0f8d33be25cc49e0.tar.gz
historical-7355f712db61f18bfc0fc29f0f8d33be25cc49e0.tar.bz2
historical-7355f712db61f18bfc0fc29f0f8d33be25cc49e0.zip
* added dlz support, closing bug #94638
Package-Manager: portage-2.0.51.22-r1
Diffstat (limited to 'net-dns/bind')
-rw-r--r--net-dns/bind/ChangeLog9
-rw-r--r--net-dns/bind/Manifest43
-rw-r--r--net-dns/bind/bind-9.3.1-r2.ebuild258
-rw-r--r--net-dns/bind/files/digest-bind-9.3.1-r22
-rwxr-xr-xnet-dns/bind/files/named.init72
5 files changed, 363 insertions, 21 deletions
diff --git a/net-dns/bind/ChangeLog b/net-dns/bind/ChangeLog
index c5af37c5de42..cb410e797b38 100644
--- a/net-dns/bind/ChangeLog
+++ b/net-dns/bind/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for net-dns/bind
# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-dns/bind/ChangeLog,v 1.78 2005/06/17 20:31:00 hansmi Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-dns/bind/ChangeLog,v 1.79 2005/06/23 17:37:44 voxus Exp $
+
+*bind-9.3.1-r2 (23 Jun 2005)
+
+ 23 Jun 2005; Konstantin Arkhipov <voxus@gentoo.org> +bind-9.3.1-r2.ebuild,
+ +files/named.init:
+ Added dlz-support to bind-9.3.1, ebuild submitted by
+ Francesco Riosa <vivo@gentoo.org>. Closing bug #94638.
17 Jun 2005; Michael Hanselmann <hansmi@gentoo.org> bind-9.2.5-r4.ebuild:
Stable on ppc.
diff --git a/net-dns/bind/Manifest b/net-dns/bind/Manifest
index 2a1831c9f637..7b065c0e5bb6 100644
--- a/net-dns/bind/Manifest
+++ b/net-dns/bind/Manifest
@@ -1,28 +1,31 @@
-MD5 bf7284c3e31bd3292a01fa046b3220bb metadata.xml 352
-MD5 08bbafd09df084b9cce6eb2f029ec6f4 ChangeLog 12479
+MD5 b72b91e6dd59755d11e31513ef1b8ff1 bind-9.3.1-r2.ebuild 7927
MD5 23c809afe06852c286f137645287abb4 bind-9.2.2-r3.ebuild 5708
-MD5 3beaa6a309548fea4c3a52e3fd05bcad bind-9.2.5-r4.ebuild 8190
-MD5 64fc49b753eba3d48561cc05d9d284a5 bind-9.3.1-r1.ebuild 6236
MD5 2bf2f6ce206ebeb1d8d2f1e8bca56ae4 bind-9.2.5.ebuild 7433
-MD5 dca1f666d891ce36c77564bbf7eaeeb4 files/bind-9.2.2-mysql.patch 10993
-MD5 9a06b553558342585f8ba88bd5e4c569 files/bind-9.2.5-mysql.patch 11315
-MD5 21e3efd21e18f4c660155978105f8ebe files/named.confd 351
+MD5 64fc49b753eba3d48561cc05d9d284a5 bind-9.3.1-r1.ebuild 6236
+MD5 2cb07f634d0161e1bb15c0b3aa07cd1d ChangeLog 12719
+MD5 bf7284c3e31bd3292a01fa046b3220bb metadata.xml 352
+MD5 3beaa6a309548fea4c3a52e3fd05bcad bind-9.2.5-r4.ebuild 8190
+MD5 51197afe8da37b1b453456de90ca4f25 files/127 227
+MD5 75d14cac80e71b4ac0662775064c06e2 files/bind-9.2.5-dlz-mysql.patch 11296
+MD5 620cf3c88d615f841884ee25bc8f8397 files/named.init 1641
MD5 309110e09d923344a34a803f8906fae3 files/digest-bind-9.2.2-r3 121
-MD5 412d666c947769b6015a65a42bb8ea00 files/named.rc6 1434
-MD5 2bb12cfcd70284e72fbf9e70e5e2974d files/dyndns-samples.tbz2 22866
+MD5 d47c8a742a2645377ba4d783907700dd files/digest-bind-9.2.5-r4 127
+MD5 a8ffc671392ffacafb5c49ffc1c6a4c6 files/named.rc6-pid_fix 488
MD5 c46a805da6650356db77b023d4d042d8 files/digest-bind-9.3.1-r1 63
+MD5 708e6dd2ce57583129d00b3d721bc3a4 files/digest-bind-9.3.1-r2 133
MD5 4346332cc9681502a3aedfd0a7a1ac41 files/bind-9.2.5-berkdb_fix.patch 537
-MD5 42b5ed5adcee33cf40531d7955412b21 files/10bind.env 27
-MD5 b3af799ce2505e78a14bb16868cf0593 files/named.conf-r1 758
-MD5 ccfca63035b534556c3910270d40a4b9 files/localhost.zone 412
-MD5 be5fd752bdbd59385f2a559d603098d5 files/named.conf-r3 1314
MD5 0eab8a4d5b98b79f76b136ab0dffabcf files/named.rc6-smart_pid_fix 1204
-MD5 d47c8a742a2645377ba4d783907700dd files/digest-bind-9.2.5-r4 127
-MD5 e9bb1e01cf0b7597e739e889499ddd7a files/named.conf-r2 768
+MD5 9a06b553558342585f8ba88bd5e4c569 files/bind-9.2.5-mysql.patch 11315
+MD5 d47c8a742a2645377ba4d783907700dd files/digest-bind-9.2.5 127
+MD5 21e3efd21e18f4c660155978105f8ebe files/named.confd 351
MD5 51197afe8da37b1b453456de90ca4f25 files/127.zone 227
-MD5 51197afe8da37b1b453456de90ca4f25 files/127 227
-MD5 e83e7a76e253debfdd120311fda73fb6 files/named.ca 2518
-MD5 a8ffc671392ffacafb5c49ffc1c6a4c6 files/named.rc6-pid_fix 488
MD5 ccfca63035b534556c3910270d40a4b9 files/localhost 412
-MD5 75d14cac80e71b4ac0662775064c06e2 files/bind-9.2.5-dlz-mysql.patch 11296
-MD5 d47c8a742a2645377ba4d783907700dd files/digest-bind-9.2.5 127
+MD5 b3af799ce2505e78a14bb16868cf0593 files/named.conf-r1 758
+MD5 e9bb1e01cf0b7597e739e889499ddd7a files/named.conf-r2 768
+MD5 be5fd752bdbd59385f2a559d603098d5 files/named.conf-r3 1314
+MD5 ccfca63035b534556c3910270d40a4b9 files/localhost.zone 412
+MD5 dca1f666d891ce36c77564bbf7eaeeb4 files/bind-9.2.2-mysql.patch 10993
+MD5 2bb12cfcd70284e72fbf9e70e5e2974d files/dyndns-samples.tbz2 22866
+MD5 412d666c947769b6015a65a42bb8ea00 files/named.rc6 1434
+MD5 42b5ed5adcee33cf40531d7955412b21 files/10bind.env 27
+MD5 e83e7a76e253debfdd120311fda73fb6 files/named.ca 2518
diff --git a/net-dns/bind/bind-9.3.1-r2.ebuild b/net-dns/bind/bind-9.3.1-r2.ebuild
new file mode 100644
index 000000000000..ff110fcf2e8c
--- /dev/null
+++ b/net-dns/bind/bind-9.3.1-r2.ebuild
@@ -0,0 +1,258 @@
+# Copyright 1999-2005 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-dns/bind/bind-9.3.1-r2.ebuild,v 1.1 2005/06/23 17:37:44 voxus Exp $
+
+inherit eutils libtool
+
+DESCRIPTION="BIND - Berkeley Internet Name Domain - Name Server"
+HOMEPAGE="http://www.isc.org/products/BIND/bind9.html"
+
+SRC_URI="ftp://ftp.isc.org/isc/bind9/${PV}/${P}.tar.gz
+ dlz? ( http://projects.navynet.it/DLZ/ctrix_dlz_9.3.1-1.patch.gz )"
+
+LICENSE="as-is"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86"
+IUSE="ssl ipv6 doc dlz postgres berkdb mysql odbc ldap selinux idn threads"
+
+DEPEND="sys-apps/groff
+ sys-devel/autoconf
+ ssl? ( >=dev-libs/openssl-0.9.6g )
+ mysql? ( >=dev-db/mysql-4 )
+ odbc? ( >=dev-db/unixODBC-2.2.6 )
+ ldap? ( net-nds/openldap )"
+
+RDEPEND="${DEPEND}
+ selinux? ( sec-policy/selinux-bind )"
+
+pkg_setup() {
+ if use dlz && use idn;
+ then
+ echo
+ eerror "DLZ currently doesn't supports IDN"
+ eerror "You should disable 'idn' or 'dlz' use flag to continue"
+
+ die "dlz doesn't support idn currently"
+ fi
+}
+
+src_unpack() {
+ unpack ${A} && cd ${S}
+
+ # Adjusting PATHs in manpages
+ for i in `echo bin/{named/named.8,check/named-checkconf.8,rndc/rndc.8}`; do
+ sed -i -e 's:/etc/named.conf:/etc/bind/named.conf:g' \
+ -e 's:/etc/rndc.conf:/etc/bind/rndc.conf:g' \
+ -e 's:/etc/rndc.key:/etc/bind/rndc.key:g' \
+ ${i}
+ done
+
+ use dlz && {
+ epatch ${DISTDIR}/ctrix_dlz_${PV}-1.patch.gz || \
+ die "dlz patch failed"
+ }
+
+ use idn && {
+ epatch ${S}/contrib/idn/idnkit-1.0-src/patch/bind9/${P}-patch || \
+ die "idn patch failed"
+ }
+
+ # it should be installed by bind-tools
+ sed "s:nsupdate ::g" ${S}/bin/Makefile.in > ${T}/Makefile
+ mv ${T}/Makefile ${S}/bin/Makefile.in
+
+ cd ${S}
+ WANT_AUTOCONF=2.5 autoconf || die "autoconf failed"
+}
+
+src_compile() {
+ local myconf=""
+
+ use ssl && myconf="${myconf} --with-openssl"
+
+ use dlz && {
+ myconf="${myconf} --with-dlz-filesystem --with-dlz-stub"
+ use postgres && myconf="${myconf} --with-dlz-postgres"
+ use mysql && myconf="${myconf} --with-dlz-mysql"
+ use berkdb && myconf="${myconf} --with-dlz-bdb"
+ use ldap && myconf="${myconf} --with-dlz-ldap"
+ use odbc && myconf="${myconf} --with-dlz-odbc"
+ }
+
+ if use threads; then
+ if use dlz && use mysql; then
+ echo
+ ewarn ""
+ einfo "MySQL uses thread local storage in its C api. Thus MySQL"
+ einfo "requires that each thread of an application execute a MySQL"
+ einfo "\"thread initialization\" to setup the thread local storage."
+ einfo "This is impossible to do safely while staying within the DLZ"
+ einfo "driver API. This is a limitation caused by MySQL, and not"
+ einfo "the DLZ API."
+ ewarn "Because of this BIND MUST only run with a single thread when"
+ ewarn "using the MySQL driver."
+ echo
+ myconf="${myconf} --disable-threads"
+ einfo "Threading support disabled"
+ epause 10
+ else
+ myconf="${myconf} --enable-linux-caps --enable-threads"
+ einfo "Threading support enabled"
+ fi
+ fi
+
+ econf \
+ --sysconfdir=/etc/bind \
+ --localstatedir=/var \
+ --with-libtool \
+ `use_enable ipv6` \
+ ${myconf} || die "econf failed"
+
+ emake -j1 || die "failed to compile bind"
+
+ use idn && {
+ cd ${S}/contrib/idn/idnkit-1.0-src
+ econf || die "idn econf failed"
+ emake || die "idn emake failed"
+ }
+}
+
+src_install() {
+ einstall || die "failed to install bind"
+
+ dodoc CHANGES COPYRIGHT FAQ README
+
+ use doc && {
+ docinto misc
+ dodoc doc/misc/*
+
+ docinto html
+ dohtml doc/arm/*
+
+ docinto draft
+ dodoc doc/draft/*
+
+ docinto rfc
+ dodoc doc/rfc/*
+
+ docinto contrib
+ dodoc contrib/named-bootconf/named-bootconf.sh \
+ contrib/nanny/nanny.pl
+
+ # some handy-dandy dynamic dns examples
+ cd ${D}/usr/share/doc/${PF}
+ tar pjxf ${FILESDIR}/dyndns-samples.tbz2
+ }
+
+ insinto /etc/env.d
+ newins ${FILESDIR}/10bind.env 10bind
+
+ dodir /etc/bind /var/bind/{pri,sec}
+ keepdir /var/bind/sec
+
+ insinto /etc/bind ; newins ${FILESDIR}/named.conf-r2 named.conf
+ # ftp://ftp.rs.internic.net/domain/named.ca:
+ insinto /var/bind ; doins ${FILESDIR}/named.ca
+ insinto /var/bind/pri ; doins ${FILESDIR}/{127,localhost}.zone
+
+ exeinto /etc/init.d ; newexe ${FILESDIR}/named.init named
+ insinto /etc/conf.d ; newins ${FILESDIR}/named.confd named
+
+ dosym ../../var/bind/named.ca /var/bind/root.cache
+ dosym ../../var/bind/pri /etc/bind/pri
+ dosym ../../var/bind/sec /etc/bind/sec
+
+ if use idn; then
+ cd ${S}/contrib/idn/idnkit-1.0-src
+ einstall || die "failed to install idn kit"
+ docinto idn
+ dodoc ChangeLog INSTALL{,.ja} README{,.ja} NEWS
+ fi
+
+ # Let's get rid of those tools and their manpages since they're provided by bind-tools
+ rm -f ${D}/usr/share/man/man1/{dig.1,host.1,nslookup.1}
+ rm -f ${D}/usr/bin/{dig,host,nslookup}
+}
+
+pkg_postinst() {
+ if [ ! -f '/etc/bind/rndc.key' ]; then
+ /usr/sbin/rndc-confgen -a -u named
+ fi
+
+ install -d -o named -g named ${ROOT}/var/run/named \
+ ${ROOT}/var/bind/pri ${ROOT}/var/bind/sec
+ chown -R named:named ${ROOT}/var/bind
+
+ einfo "The default zone files are now installed as *.zone,"
+ einfo "be careful merging config files if you have modified"
+ einfo "/var/bind/pri/127 or /var/bind/pri/localhost"
+ einfo
+ einfo "You can edit /etc/conf.d/named to customize named settings"
+ einfo
+ einfo "The BIND ebuild now includes chroot support."
+ einfo "If you like to run bind in chroot AND this is a new install OR"
+ einfo "your bind doesn't already run in chroot, simply run:"
+ einfo "\`ebuild /var/db/pkg/${CATEGORY}/${PF}/${PF}.ebuild config\`"
+ einfo "Before running the above command you might want to change the chroot"
+ einfo "dir in /etc/conf.d/named. Otherwise /chroot/dns will be used."
+ echo
+ einfo "Recently verisign added a wildcard A record to the .COM and .NET TLD"
+ einfo "zones making all .com and .net domains appear to be registered"
+ einfo "This causes many problems such as breaking important anti-spam checks"
+ einfo "which verify source domains exist. ISC released a patch for BIND which"
+ einfo "adds 'delegation-only' zones to allow admins to return the .com and .net"
+ einfo "domain resolution to their normal function."
+ echo
+ einfo "There is no need to create a com or net data file. Just the"
+ einfo "entries to the named.conf file is enough."
+ echo
+ einfo " zone "com" IN { type delegation-only; };"
+ einfo " zone "net" IN { type delegation-only; };"
+
+ echo
+ ewarn "BIND >=9.2.5 makes the priority argument to MX records mandatory"
+ ewarn "when it was previously optional. If the priority is missing, BIND"
+ ewarn "won't load the zone file at all."
+ echo
+}
+
+pkg_config() {
+ CHROOT=`sed -n 's/^[[:blank:]]\?CHROOT="\([^"]\+\)"/\1/p' /etc/conf.d/named 2>/dev/null`
+ EXISTS="no"
+
+ if [ -z "${CHROOT}" -a ! -d "/chroot/dns" ]; then
+ CHROOT="/chroot/dns"
+ elif [ -d ${CHROOT} ]; then
+ eerror; eerror "${CHROOT:-/chroot/dns} already exists. Quitting."; eerror; EXISTS="yes"
+ fi
+
+ if [ ! "$EXISTS" = yes ]; then
+ einfo ; einfon "Setting up the chroot directory..."
+ mkdir -m 700 -p ${CHROOT}
+ mkdir -p ${CHROOT}/{dev,etc,var/run/named}
+ chown -R named:named ${CHROOT}/var/run/named
+ cp -R /etc/bind ${CHROOT}/etc/
+ cp /etc/localtime ${CHROOT}/etc/localtime
+ chown named:named ${CHROOT}/etc/bind/rndc.key
+ cp -R /var/bind ${CHROOT}/var/
+ chown -R named:named ${CHROOT}/var/
+ mknod ${CHROOT}/dev/zero c 1 5
+ mknod ${CHROOT}/dev/random c 1 8
+ chmod 666 ${CHROOT}/dev/{random,zero}
+ chown named:named ${CHROOT}
+
+ grep -q "^#[[:blank:]]\?CHROOT" /etc/conf.d/named ; RETVAL=$?
+ if [ $RETVAL = 0 ]; then
+ sed 's/^# \?\(CHROOT.*\)$/\1/' /etc/conf.d/named > /etc/conf.d/named.orig 2>/dev/null
+ mv --force /etc/conf.d/named.orig /etc/conf.d/named
+ fi
+
+ sleep 1; echo " Done."; sleep 1
+ einfo
+ einfo "Add the following to your root .bashrc or .bash_profile: "
+ einfo " alias rndc='rndc -k ${CHROOT}/etc/bind/rndc.key'"
+ einfo "Then do the following: "
+ einfo " source /root/.bashrc or .bash_profile"
+ einfo
+ fi
+}
diff --git a/net-dns/bind/files/digest-bind-9.3.1-r2 b/net-dns/bind/files/digest-bind-9.3.1-r2
new file mode 100644
index 000000000000..4307a2849697
--- /dev/null
+++ b/net-dns/bind/files/digest-bind-9.3.1-r2
@@ -0,0 +1,2 @@
+MD5 9ff3204eea27184ea0722f37e43fc95d bind-9.3.1.tar.gz 4673603
+MD5 bdc1edae00952181438947716a53c2b0 ctrix_dlz_9.3.1-1.patch.gz 92434
diff --git a/net-dns/bind/files/named.init b/net-dns/bind/files/named.init
new file mode 100755
index 000000000000..ff556bc969dc
--- /dev/null
+++ b/net-dns/bind/files/named.init
@@ -0,0 +1,72 @@
+#!/sbin/runscript
+# Copyright 1999-2004 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-dns/bind/files/named.init,v 1.1 2005/06/23 17:37:44 voxus Exp $
+
+opts="start stop reload restart"
+
+depend() {
+ need net
+ use logger
+ provide dns
+}
+
+checkconfig() {
+ if [ ! -f ${CHROOT}/etc/bind/named.conf ] ; then
+ eerror "No ${CHROOT}/etc/bind/named.conf file exists!"
+ fi
+
+ # In case someone doesn't have $CPU set from /etc/conf.d/named
+ if [ ! ${CPU} ] ; then
+ CPU="1"
+ fi
+
+ # As with the named.conf test, above, there's no need
+ # for chroot and non-chroot cases here
+ PIDFILE=$(grep "pid-file" ${CHROOT}/etc/bind/named.conf | \
+ egrep -v ".*[#,//].*pid-file" | \
+ head -n 1 | \
+ sed -ne 's:.*pid-file \"\(.*\)\";:\1:p')
+ [ -n "$PIDFILE" ] || PIDFILE=/var/run/named.pid
+
+ PIDFILE="${CHROOT}$PIDFILE"
+
+ KEY="${CHROOT}/etc/bind/rndc.key"
+}
+
+start() {
+ ebegin "Starting ${CHROOT:+chrooted }named"
+ checkconfig || return 1
+ start-stop-daemon --start --quiet --pidfile ${PIDFILE} \
+ --exec /usr/sbin/named \
+ -- -u named -n ${CPU} ${OPTIONS} ${CHROOT:+-t $CHROOT}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping ${CHROOT:+chrooted }named"
+ checkconfig || return 2
+ start-stop-daemon --stop --quiet --pidfile $PIDFILE \
+ --exec /usr/sbin/named -- stop
+ eend $?
+}
+
+reload() {
+ checkconfig || return 3
+ if [ ! -f $PIDFILE ] ; then
+ /etc/init.d/named start &>/dev/null
+ exit
+ fi
+
+ if [ -f $KEY ] ; then
+ ebegin "Reloading named.conf and zone files"
+ rndc -k $KEY reload &>/dev/null
+ eend $?
+ else /etc/init.d/named restart &>/dev/null
+ fi
+}
+
+restart() {
+ svc_stop
+ svc_start
+}