summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTony Vroon <chainsaw@gentoo.org>2008-06-27 10:10:50 +0000
committerTony Vroon <chainsaw@gentoo.org>2008-06-27 10:10:50 +0000
commit605f99f596bc79dc9be478a916569af8263b80f9 (patch)
tree19cf177b29343a9c75365b459e9d8d9275e6721a /net-misc/dhcp
parentChange dependency from virtual/motif to x11-libs/openmotif, bug 224749. (diff)
downloadhistorical-605f99f596bc79dc9be478a916569af8263b80f9.tar.gz
historical-605f99f596bc79dc9be478a916569af8263b80f9.tar.bz2
historical-605f99f596bc79dc9be478a916569af8263b80f9.zip
Version bump for bug #227135.
Package-Manager: portage-2.2_rc1/cvs/Linux 2.6.26-rc7-00051-g62786b9-dirty x86_64
Diffstat (limited to 'net-misc/dhcp')
-rw-r--r--net-misc/dhcp/ChangeLog7
-rw-r--r--net-misc/dhcp/Manifest12
-rw-r--r--net-misc/dhcp/dhcp-3.1.1.ebuild238
3 files changed, 251 insertions, 6 deletions
diff --git a/net-misc/dhcp/ChangeLog b/net-misc/dhcp/ChangeLog
index 09ef6bfc61e4..251e008495c0 100644
--- a/net-misc/dhcp/ChangeLog
+++ b/net-misc/dhcp/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for net-misc/dhcp
# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcp/ChangeLog,v 1.142 2008/03/29 19:47:53 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcp/ChangeLog,v 1.143 2008/06/27 10:10:50 chainsaw Exp $
+
+*dhcp-3.1.1 (27 Jun 2008)
+
+ 27 Jun 2008; <chainsaw@gentoo.org> +dhcp-3.1.1.ebuild:
+ Version bump for bug #227135.
29 Mar 2008; Mike Frysinger <vapier@gentoo.org>
files/dhcp-3.0.3-dhclient-ntp.patch,
diff --git a/net-misc/dhcp/Manifest b/net-misc/dhcp/Manifest
index c488daab5911..f496cf069b16 100644
--- a/net-misc/dhcp/Manifest
+++ b/net-misc/dhcp/Manifest
@@ -27,15 +27,17 @@ AUX dhcrelay.init 736 RMD160 04566b87bd6dbb8bb754b26409ca30b878ef3ca3 SHA1 72742
DIST dhcp-3.0.3.tar.gz 870240 RMD160 bcbd1f8b49f17809a3473103a7b5e096c45855d7 SHA1 1e2e6c3ecdb8046a39aaabe1a36171e1d45d21e4 SHA256 c96bcd884dde06c22a709cfb9e84f7e32f6577dcd52aa7f12186aa22b5e63afe
DIST dhcp-3.0.6.tar.gz 891513 RMD160 6b7dbad413f83f9bce4ed92a8abc60394a06c6ad SHA1 204e509580d57d0cfff23529274612ca8c710efb SHA256 9f77b0ebf975d71578e2d305a2e07b900a9462b7efaac41826facfb4d4f00f4d
DIST dhcp-3.1.0.tar.gz 797100 RMD160 59ef8b695b66d3cb61437e25a179d9f17639017d SHA1 f33d017f055648e6571aa26cf314d37857491a2e SHA256 26d02217f53e40ab7c7140cf58d99b55a64979c8501481b28da9c432f0f92243
+DIST dhcp-3.1.1.tar.gz 798228 RMD160 08ed15d26ca64928e1d3b07c631cbbfa9a3dc8cb SHA1 3f7e013cb62aed0f3af45bdd97424d8b63e9c280 SHA256 129024c7545e3e8d37e75cd5d534b50c53955592c4935189a57916e216355f6d
EBUILD dhcp-3.0.3-r9.ebuild 7186 RMD160 e59315a08a6b382915ec7ded0a4c7cfa38c9a5de SHA1 6c11653e84a8f3e81913f3916dabb6d6a38aedb5 SHA256 eee8b146f259da6645b0f901038e63f6c9d4dec8ffd1627c997ad8fde76338b0
EBUILD dhcp-3.0.6.ebuild 7532 RMD160 8b67dd9acc7d1f392a6fd7d1d3a1e9ce8c00460b SHA1 c0b406cc528a97db2409324688e3a7ab93862677 SHA256 e550750c928525b090ff08087df2a9f63764805d663aee72b8991244a417e509
EBUILD dhcp-3.1.0.ebuild 7431 RMD160 bd267b1ae0ee8568ae5b8fce5267a41258fb5d48 SHA1 b77e78900b054ee2fd06f1059fff84cc1db3499c SHA256 a2a75e7c2e1b60c84a49f66d59360571534c1ea5245e6a8a14d8c039c1115bfb
-MISC ChangeLog 24102 RMD160 59bb22b91d4bb1503fa02192e4920550782d6f34 SHA1 5656e85d8322ac95fc227ebb596613d135c6ed82 SHA256 82ed3b7eb9f42b249f22fd3c88bf846f499051d9ed8a3af9ca37fe9e1888382e
+EBUILD dhcp-3.1.1.ebuild 7443 RMD160 e37f0f8f187d37ca5df959500a138aaf3679575b SHA1 77f7a9cb3d720278f0ad6f997000faa238baf106 SHA256 f51165120436b69497e4c45233cdb8d264e828cd2637eec2a5504d9be7cd7067
+MISC ChangeLog 24221 RMD160 3b131ffeab195c126c75bbdf60c005d2f79a92bd SHA1 4479e435435cb1b1c669e4d5659be46e2d544f8f SHA256 0db4819a6c1c4ae9707b7b8d08d6973db1f3d094b1e5173600d3a3f1a472e005
MISC metadata.xml 358 RMD160 97ecd4b6ee0a24352a71a66d5ad4fd82481156b4 SHA1 d80da2cf7c6892cdad6b681fda29e46472d68871 SHA256 8665f24cdfcc09576b595f8bd257333ff5f9ea7ee0ca2925ba6fb74d90e12415
-----BEGIN PGP SIGNATURE-----
-Version: GnuPG v2.0.7 (GNU/Linux)
+Version: GnuPG v2.0.9 (GNU/Linux)
-iD8DBQFH7p28j9hvisErhMIRAshaAKDM1Nk5MMw5YBUbFgrRYHVPsnojOwCggDKx
-7oouYX3+rY/CNqS9z5oW9E0=
-=+XZK
+iEYEARECAAYFAkhkvHAACgkQp5vW4rUFj5qEnwCdHqUOTDvDHNmr43PtBt6/D82c
+SIQAn3qCodkI7CrzuXvMps0fBp0xBbRc
+=Djh7
-----END PGP SIGNATURE-----
diff --git a/net-misc/dhcp/dhcp-3.1.1.ebuild b/net-misc/dhcp/dhcp-3.1.1.ebuild
new file mode 100644
index 000000000000..0bd092a897d0
--- /dev/null
+++ b/net-misc/dhcp/dhcp-3.1.1.ebuild
@@ -0,0 +1,238 @@
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcp/dhcp-3.1.1.ebuild,v 1.1 2008/06/27 10:10:50 chainsaw Exp $
+
+inherit eutils flag-o-matic multilib toolchain-funcs
+
+MY_PV="${PV//_alpha/a}"
+MY_PV="${MY_PV//_beta/b}"
+MY_PV="${MY_PV//_rc/rc}"
+MY_P="${PN}-${MY_PV}"
+DESCRIPTION="ISC Dynamic Host Configuration Protocol"
+HOMEPAGE="http://www.isc.org/products/DHCP"
+SRC_URI="ftp://ftp.isc.org/isc/dhcp/${MY_P}.tar.gz"
+
+LICENSE="isc-dhcp"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~sparc-fbsd ~x86 ~x86-fbsd"
+IUSE="doc minimal static selinux kernel_linux"
+
+DEPEND="selinux? ( sec-policy/selinux-dhcp )
+ kernel_linux? ( sys-apps/net-tools )"
+
+PROVIDE="virtual/dhcpc"
+
+S="${WORKDIR}/${MY_P}"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+
+ # Gentoo patches - these will probably never be accepted upstream
+ # Enable chroot support
+ epatch "${FILESDIR}/${PN}"-3.0-paranoia.patch
+ # Fix some permission issues
+ epatch "${FILESDIR}/${PN}"-3.0-fix-perms.patch
+ # Enable dhclient to equery NTP servers
+ epatch "${FILESDIR}/${PN}"-3.0.3-dhclient-ntp.patch
+ # resolvconf support in dhclient-script
+ epatch "${FILESDIR}/${PN}"-3.1.0a1-dhclient-resolvconf.patch
+ # Fix setting hostnames on Linux
+ epatch "${FILESDIR}/${PN}"-3.0.3-dhclient-hostname.patch
+ # Allow mtu settings
+ epatch "${FILESDIR}/${PN}"-3.0.3-dhclient-mtu.patch
+ # Allow dhclient to use IF_METRIC to set route metrics
+ epatch "${FILESDIR}/${PN}"-3.0.3-dhclient-metric.patch
+ # Stop downing the interface on Linux as that breaks link dameons
+ # such as wpa_supplicant and netplug
+ epatch "${FILESDIR}/${PN}"-3.0.3-dhclient-no-down.patch
+ # Quiet the isc blurb
+ epatch "${FILESDIR}/${PN}"-3.0.3-no_isc_blurb.patch
+ # Enable dhclient to get extra configuration from stdin
+ epatch "${FILESDIR}/${PN}"-3.0.4-dhclient-stdin-conf.patch
+ # Disable fallback interfaces when using BPF
+ # This allows more than one dhclient instance on the BSD's
+ epatch "${FILESDIR}/${PN}"-3.0.5-bpf-nofallback.patch
+
+ # General fixes which will probably be accepted upstream eventually
+ # Install libdst, #75544
+ epatch "${FILESDIR}/${PN}"-3.0.3-libdst.patch
+ # Fix building on Gentoo/FreeBSD
+ epatch "${FILESDIR}/${PN}"-3.0.2-gmake.patch
+
+ # NetworkManager support patches
+ # If they fail to apply to future versions they will be dropped
+ # Add dbus support to dhclient
+ epatch "${FILESDIR}/${PN}"-3.0.3-dhclient-dbus.patch
+
+ # Brand the version with Gentoo
+ # include revision if >0
+ local newver="${MY_PV}-Gentoo"
+ [[ ${PR} != "r0" ]] && newver="${newver}-${PR}"
+ sed -i '/^#define DHCP_VERSION[ \t]\+/ s/'"${MY_PV}/${newver}/g" \
+ includes/version.h || die
+
+ # Change the hook script locations of the scripts
+ sed -i -e 's,/etc/dhclient-exit-hooks,/etc/dhcp/dhclient-exit-hooks,g' \
+ -e 's,/etc/dhclient-enter-hooks,/etc/dhcp/dhclient-enter-hooks,g' \
+ client/scripts/* || die
+
+ # No need for the linux script to force bash, #158540.
+ sed -i -e 's,#!/bin/bash,#!/bin/sh,' client/scripts/linux || die
+
+ # Quiet the freebsd logger a little
+ sed -i -e '/LOGGER=/ s/-s -p user.notice //g' client/scripts/freebsd || die
+
+ # Remove these options from the sample config
+ sed -i -e "/\(script\|host-name\|domain-name\) / d" \
+ client/dhclient.conf || die
+
+ # Build sed man pages as we don't ever support BSD 4.4 and older, #130251.
+ local x=
+ for x in Makefile.dist $(ls */Makefile.dist) ; do
+ sed -i -e 's/$(CATMANPAGES)/$(SEDMANPAGES)/g' "${x}" || die
+ done
+
+ # Only install different man pages if we don't have en
+ if [[ " ${LINGUAS} " != *" en "* ]]; then
+ # Install Japanese man pages
+ if [[ " ${LINGUAS} " == *" ja "* && -d doc/ja_JP.eucJP ]]; then
+ einfo "Installing Japanese documention"
+ cp doc/ja_JP.eucJP/dhclient* client
+ cp doc/ja_JP.eucJP/dhcp* common
+ fi
+ fi
+
+ # Now remove the non-english docs so there are no errors later
+ [[ -d doc/ja_JP.eucJP ]] && rm -rf doc/ja_JP.eucJP
+}
+
+src_compile() {
+ use static && append-ldflags -static
+
+ cat <<-END >> includes/site.h
+ #define _PATH_DHCPD_CONF "/etc/dhcp/dhcpd.conf"
+ #define _PATH_DHCPD_PID "/var/run/dhcp/dhcpd.pid"
+ #define _PATH_DHCPD_DB "/var/lib/dhcp/dhcpd.leases"
+ #define _PATH_DHCLIENT_CONF "/etc/dhcp/dhclient.conf"
+ #define _PATH_DHCLIENT_DB "/var/lib/dhcp/dhclient.leases"
+ #define _PATH_DHCLIENT_PID "/var/run/dhcp/dhclient.pid"
+ #define DHCPD_LOG_FACILITY LOG_LOCAL1
+ END
+
+ cat <<-END > site.conf
+ CC = $(tc-getCC)
+ LFLAGS = ${LDFLAGS}
+ LIBDIR = /usr/$(get_libdir)
+ INCDIR = /usr/include
+ ETC = /etc/dhcp
+ VARDB = /var/lib/dhcp
+ VARRUN = /var/run/dhcp
+ ADMMANDIR = /usr/share/man/man8
+ ADMMANEXT = .8
+ FFMANDIR = /usr/share/man/man5
+ FFMANEXT = .5
+ LIBMANDIR = /usr/share/man/man3
+ LIBMANEXT = .3
+ USRMANDIR = /usr/share/man/man1
+ USRMANEXT = .1
+ MANCAT = man
+ END
+
+ ./configure --copts "-DPARANOIA -DEARLY_CHROOT ${CFLAGS}" \
+ || die "configure failed"
+
+ # Remove server support from the Makefile
+ # We still install some extra crud though
+ if use minimal ; then
+ sed -i -e 's/\(server\|relay\|dhcpctl\)/ /g' work.*/Makefile || die
+ fi
+ emake || die "compile problem"
+}
+
+src_install() {
+ make install DESTDIR="${D}" || die
+ use doc && dodoc README RELNOTES doc/*
+
+ insinto /etc/dhcp
+ newins client/dhclient.conf dhclient.conf.sample
+ keepdir /var/{lib,run}/dhcp
+
+ # Install our server files
+ if ! use minimal ; then
+ insinto /etc/dhcp
+ newins server/dhcpd.conf dhcpd.conf.sample
+ newinitd "${FILESDIR}"/dhcpd.init dhcpd
+ newinitd "${FILESDIR}"/dhcrelay.init dhcrelay
+ newconfd "${FILESDIR}"/dhcpd.conf dhcpd
+ newconfd "${FILESDIR}"/dhcrelay.conf dhcrelay
+
+ # We never want portage to own this file
+ rm -f "${D}"/var/lib/dhcp/dhcpd.leases
+ fi
+}
+
+pkg_preinst() {
+ if ! use minimal ; then
+ enewgroup dhcp
+ enewuser dhcp -1 -1 /var/lib/dhcp dhcp
+ fi
+}
+
+pkg_postinst() {
+ use minimal && return
+
+ chown dhcp:dhcp "${ROOT}"/var/{lib,run}/dhcp
+
+ if [[ -e "${ROOT}"/etc/init.d/dhcp ]] ; then
+ ewarn
+ ewarn "WARNING: The dhcp init script has been renamed to dhcpd"
+ ewarn "/etc/init.d/dhcp and /etc/conf.d/dhcp need to be removed and"
+ ewarn "and dhcp should be removed from the default runlevel"
+ ewarn
+ fi
+
+ einfo "You can edit /etc/conf.d/dhcpd to customize dhcp settings."
+ einfo
+ einfo "If you would like to run dhcpd in a chroot, simply configure the"
+ einfo "DHCPD_CHROOT directory in /etc/conf.d/dhcpd and then run:"
+ einfo " emerge --config =${PF}"
+}
+
+pkg_config() {
+ if use minimal ; then
+ eerror "${PN} has not been compiled for server support"
+ eerror "emerge ${PN} without the minimal USE flag to use dhcp sever"
+ return 1
+ fi
+
+ local CHROOT="$(
+ sed -n -e 's/^[[:blank:]]\?DHCPD_CHROOT="*\([^#"]\+\)"*/\1/p' \
+ "${ROOT}"/etc/conf.d/dhcpd
+ )"
+
+ if [[ -z ${CHROOT} ]]; then
+ eerror "CHROOT not defined in /etc/conf.d/dhcpd"
+ return 1
+ fi
+
+ CHROOT="${ROOT}/${CHROOT}"
+
+ if [[ -d ${CHROOT} ]] ; then
+ ewarn "${CHROOT} already exists - aborting"
+ return 0
+ fi
+
+ ebegin "Setting up the chroot directory"
+ mkdir -m 0755 -p "${CHROOT}/"{dev,etc,var/lib,var/run/dhcp}
+ cp /etc/{localtime,resolv.conf} "${CHROOT}"/etc
+ cp -R /etc/dhcp "${CHROOT}"/etc
+ cp -R /var/lib/dhcp "${CHROOT}"/var/lib
+ ln -s ../../var/lib/dhcp "${CHROOT}"/etc/dhcp/lib
+ chown -R dhcp:dhcp "${CHROOT}"/var/{lib,run}/dhcp
+ eend 0
+
+ local logger="$(best_version virtual/logger)"
+ einfo "To enable logging from the dhcpd server, configure your"
+ einfo "logger (${logger}) to listen on ${CHROOT}/dev/log"
+}