diff options
Diffstat (limited to 'net-dns/ndu')
-rw-r--r-- | net-dns/ndu/Manifest | 1 | ||||
-rw-r--r-- | net-dns/ndu/files/ndu-0.4-binary-locations.patch | 14 | ||||
-rw-r--r-- | net-dns/ndu/metadata.xml | 8 | ||||
-rw-r--r-- | net-dns/ndu/ndu-0.4-r4.ebuild | 60 |
4 files changed, 83 insertions, 0 deletions
diff --git a/net-dns/ndu/Manifest b/net-dns/ndu/Manifest new file mode 100644 index 000000000000..c07a3bb490d4 --- /dev/null +++ b/net-dns/ndu/Manifest @@ -0,0 +1 @@ +DIST ndu-0.4.tar.gz 16118 RMD160 f9273a4428dd30a0bca3416cfcab15aa5fb04aa3 SHA1 10719a426e16291e351ad057784474a0b606078f SHA256 27a2f523cee765db142b5582087866a90050fa00f1b365c800305204fc0c6d40 diff --git a/net-dns/ndu/files/ndu-0.4-binary-locations.patch b/net-dns/ndu/files/ndu-0.4-binary-locations.patch new file mode 100644 index 000000000000..4007b4dc4216 --- /dev/null +++ b/net-dns/ndu/files/ndu-0.4-binary-locations.patch @@ -0,0 +1,14 @@ +diff -Nuar --exclude '*~' ndu-0.4.orig/src/dnsedit ndu-0.4/src/dnsedit +--- ndu-0.4.orig/src/dnsedit 2006-05-22 16:16:47.000000000 -0700 ++++ ndu-0.4/src/dnsedit 2006-05-22 16:20:45.107741010 -0700 +@@ -19,8 +19,8 @@ + if /usr/bin/diff $1 $tempfile >> /dev/null ; then + echo No changed made + else +- /usr/sbin/dnstouch $1 +- /usr/sbin/ndu ++ /usr/bin/dnstouch $1 ++ /usr/bin/ndu + # /usr/sbin/ndc reload + echo updated + fi diff --git a/net-dns/ndu/metadata.xml b/net-dns/ndu/metadata.xml new file mode 100644 index 000000000000..a732fd8b2f03 --- /dev/null +++ b/net-dns/ndu/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer> + <email>robbat2@gentoo.org</email> + <name>Robin H. Johnson</name> + </maintainer> +</pkgmetadata> diff --git a/net-dns/ndu/ndu-0.4-r4.ebuild b/net-dns/ndu/ndu-0.4-r4.ebuild new file mode 100644 index 000000000000..7ae42140425a --- /dev/null +++ b/net-dns/ndu/ndu-0.4-r4.ebuild @@ -0,0 +1,60 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +inherit eutils toolchain-funcs + +DESCRIPTION="DNS serial number incrementer and reverse zone builder" +SRC_URI="http://uranus.it.swin.edu.au/~jn/linux/${P}.tar.gz" +HOMEPAGE="http://uranus.it.swin.edu.au/~jn/linux/dns.htm" +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 ppc x86" +IUSE="" +DEPEND="sys-apps/sed" +RDEPEND="sys-apps/ed" # dnstouch calls ed to do the dirty work + +src_unpack() { + unpack ${A} + + epatch "${FILESDIR}"/${P}-binary-locations.patch + + cd "${S}"/src + # use the correct compiler + sed -e 's|gcc|$(CXX)|g' -i Makefile + # set correct config pathes + sed -e 's|#define CONFIG_PATH "/etc/"|#define CONFIG_PATH "/etc/bind/"|g' -i ndu.cpp + sed -e 's|"/etc/ndu.conf"|"/etc/bind/ndu.conf"|g' -i dnstouch.cpp + # hack up something to work around bug #73858 + sed -e 's|execlp("ed", "ed", filename, 0);|execlp("ed", "ed", "-s", filename, 0);|g' -i dnstouch.cpp + # use the correct editor + sed -e 's|VISUAL|EDITOR|g' -i dnsedit + + cd "${S}" + # match our bind config + sed -e 's|0.0.127.in-addr.arpa|127.in-addr.arpa|g' -i ndu.conf + # document the support for the chrooted BIND setup + echo '// if you use a chrooted setup, then you need to uncomment these lines:' >>ndu.conf + echo '//process "/chroot/dns/named.conf"' >>ndu.conf + echo '//chroot "/chroot/dns"' >>ndu.conf +} + +src_compile() { + cd "${S}"/src + emake CFLAGS="${CFLAGS}" CXX="$(tc-getCXX)" +} + +src_install () { + into /usr + dobin src/{dnsedit,ndu,dnstouch} + into / + insinto /etc/bind + doins ndu.conf + dodoc README INSTALL +} + +pkg_postinst() { + elog "The ndu binary expects to read your configuration" + elog "from /etc/bind/named.conf, however the other binaries" + elog "are useful with BIND locally installed." +} |