diff options
author | Mike Frysinger <vapier@gentoo.org> | 2012-05-16 05:08:40 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2012-05-16 05:08:40 +0000 |
commit | 51f6a013933ebb091e9d7a33120358cffc0a7e60 (patch) | |
tree | 045c38102341d4030ceea4bfb949976e7e70216f /net-misc/dhcp | |
parent | Pull in virtual/os-headers for soundcard.h include. (diff) | |
download | historical-51f6a013933ebb091e9d7a33120358cffc0a7e60.tar.gz historical-51f6a013933ebb091e9d7a33120358cffc0a7e60.tar.bz2 historical-51f6a013933ebb091e9d7a33120358cffc0a7e60.zip |
Version bump, and add dhcrelay6 init.d support #415957 by Spooky Ghost.
Package-Manager: portage-2.2.0_alpha102/cvs/Linux x86_64
Diffstat (limited to 'net-misc/dhcp')
-rw-r--r-- | net-misc/dhcp/ChangeLog | 8 | ||||
-rw-r--r-- | net-misc/dhcp/Manifest | 22 | ||||
-rw-r--r-- | net-misc/dhcp/dhcp-4.2.3_p2.ebuild | 237 | ||||
-rwxr-xr-x | net-misc/dhcp/files/dhcrelay.init3 | 29 | ||||
-rw-r--r-- | net-misc/dhcp/files/dhcrelay6.conf | 14 |
5 files changed, 305 insertions, 5 deletions
diff --git a/net-misc/dhcp/ChangeLog b/net-misc/dhcp/ChangeLog index 801e57d1955d..5175477b72b1 100644 --- a/net-misc/dhcp/ChangeLog +++ b/net-misc/dhcp/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for net-misc/dhcp # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcp/ChangeLog,v 1.207 2012/04/28 01:13:59 aballier Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcp/ChangeLog,v 1.208 2012/05/16 05:08:40 vapier Exp $ + +*dhcp-4.2.3_p2 (16 May 2012) + + 16 May 2012; Mike Frysinger <vapier@gentoo.org> +dhcp-4.2.3_p2.ebuild, + +files/dhcrelay.init3, +files/dhcrelay6.conf: + Version bump, and add dhcrelay6 init.d support #415957 by Spooky Ghost. 28 Apr 2012; Alexis Ballier <aballier@gentoo.org> dhcp-4.2.3_p1.ebuild: keyword ~amd64-fbsd diff --git a/net-misc/dhcp/Manifest b/net-misc/dhcp/Manifest index 7610a0d6d2ff..233c2f7a3a22 100644 --- a/net-misc/dhcp/Manifest +++ b/net-misc/dhcp/Manifest @@ -37,11 +37,14 @@ AUX dhcpd.init5 2874 RMD160 a99ea016347f184b0f95207cdf8bd2b634d4de4c SHA1 62c0b3 AUX dhcrelay.conf 421 RMD160 456edbc9bcc8d3a44db5bb6dbf0c3003c3e7419c SHA1 78ecdb000382893fb49d0052ced063955b0ad9cf SHA256 409b895ed489e75c1a08f72961b45d641b93fd9357f528abc78b1fd036b7f730 AUX dhcrelay.init 736 RMD160 04566b87bd6dbb8bb754b26409ca30b878ef3ca3 SHA1 72742b308314b2e1476b27e94212fbf4d179adc4 SHA256 cfdaff3a723be3935d06c14e171d4008f2ad3329bd05ac2e49c19bc0e14bc59c AUX dhcrelay.init2 712 RMD160 2baeaf7c0fb8a5796792b5721f32104907243798 SHA1 ced20da5625b6517fa6044ce179e1c5d9a17297e SHA256 6cca726147474c600662b0c2e49eb5aa148a7a9af1358dbc56f16b1d08255ae3 +AUX dhcrelay.init3 720 RMD160 185e193fc38c2c200663f67a3f19b24ad10edae3 SHA1 1e306482b8355143b3c92c23d5c077796af7f4ac SHA256 a97cc3ad2c5d58707a19c30848c0818395d61018dfb9c059763a0b41eaee1a13 +AUX dhcrelay6.conf 514 RMD160 c8714c219aa63f385cf96cdee4957055321535db SHA1 3dd7df4b837b1e34ee403781724e56c88277a67c SHA256 7acc8caffc3b08463e8ef7b7b66507d782138161b4c967cbe01ca1e8c975ced8 DIST dhcp-3.1-ESV.tar.gz 797454 RMD160 c6a8d943240dde72d47bb9bfbd740ff6e68ceee9 SHA1 e1cce81ead844fbdaf7ad99ba1146efa0b8b72c0 SHA256 e316b7dc34f05e38724273a473f823719281f229a71a80bc358f8e74687fd7d7 DIST dhcp-3.1.2p1.tar.gz 792355 RMD160 53434f8404c69e8e113cad030ec975cf13b467cc SHA1 730214fa6e70d187f1492aa3d4f1c2868ffcc8de SHA256 e0cb405e0fef0ecebec7aaed294032a06178ff28be87498596e6069ccda4341e DIST dhcp-4.2.1-P1.tar.gz 8797289 RMD160 e3607828ea12eb718c0877430f9607d336d78c36 SHA1 7767019313b4128357054a1eb053c66799831dd6 SHA256 6cd5e06512c53ad43d71400f39071ce0bd07f074e416c727d5bc7e5949ec55ec DIST dhcp-4.2.2.tar.gz 8764108 RMD160 a7d0a66a6156cc2194a784b120587ffd5e8e200e SHA1 a2d5d5bf0fb2a98e9e3e18b243d0a07e12837f81 SHA256 846ee115bd3a789ef4d8d051e1078b920b152c5644179c1a28ed59aa1b5ee38c DIST dhcp-4.2.3-P1.tar.gz 9525670 RMD160 fc15dc0589d698c7d1f8c8df045f0b396b30c28e SHA1 cb4b658cf9d9674fad7ee11d06193569784c61a2 SHA256 4860625e07c290768d513b9a2260e655ae4bad4cc5c4c8f5eaaeb4f9cbfa96af +DIST dhcp-4.2.3-P2.tar.gz 9527546 RMD160 445663a44b18acd2f02497b652c72656f9a0e328 SHA1 6ce113d8e6301343b66d4d71be59a3c34805378d SHA256 5cf7ae2cad9c4ca0103748b2476ec8ea78484e408f8fe597e4e0a4afb051b469 EBUILD dhcp-3.1.2_p1.ebuild 7582 RMD160 d7f42417b80f9f17e0c8c217c978707506802a22 SHA1 be9987191d730c6065c74fc8c9e8835e5d229561 SHA256 4ebe414e6dc4ce6f6b9ebf4f0bfd44b6af03330ff48c39ad7c9987ac1cae624f EBUILD dhcp-3.1.3_p1.ebuild 7741 RMD160 62ef4cf524beadef2847675416ea5982f23a3f8e SHA1 3995b5c53d6b11fde440cf43c0dacac31f084d72 SHA256 7a71c86e1685858826a09f28dff77d69a98ec1d37c93bbb6e4dd216af00ce96c EBUILD dhcp-4.2.1_p1.ebuild 6610 RMD160 0d058e755de185a58fc62a3d047021671de9a54a SHA1 5cf96d94250ba44b3120ae6a961c04e4f01996b5 SHA256 70534d654d5a2d02ea009d87f77bf86724ee94b7587f5b6959eef90475e5062a @@ -50,12 +53,23 @@ EBUILD dhcp-4.2.2-r2.ebuild 7107 RMD160 8e380ef4e9986cd4b249c1efb9eb2aba5fc3b1ef EBUILD dhcp-4.2.2-r3.ebuild 7143 RMD160 4a6450fdf6a1430e6a1c316a67dc751e4cf8f319 SHA1 57f704cc9dea37fa2e244687521d35564d7f915f SHA256 f2ce7dd86a7f37b03c832216adb08cc6b2302bb45575ba6328aeabbcc3ccfb86 EBUILD dhcp-4.2.2.ebuild 7474 RMD160 a80b1fb2eb31ba8dc20f9d6fb914e37a5cf12174 SHA1 089b6bb9e87f07c950d7ee4261e081ba59f29fa5 SHA256 9f15f5b2d35d9ff4372250886f3751b94abb0fbebc99ea4d16e5abd74ccf9755 EBUILD dhcp-4.2.3_p1.ebuild 7211 RMD160 289ef9e28b5cb390a0b393d1bf429de6eca1345d SHA1 d1a3a4b79d162e0cb2248689e2aebf7596d23d20 SHA256 663b373b3661a23ae1364ba18a52ade63022aad8229bc1b275cc82d110b07253 -MISC ChangeLog 35178 RMD160 857aa5a7d80a81441114e0f1a2b7152edc97f3c0 SHA1 2bb3293555fb688c7c5811c2458aa40c46a58ae8 SHA256 563582a7d61609eb6f34b607769853f3ad82fdfe934c4fe00e1a4c4b3e2c6a5a +EBUILD dhcp-4.2.3_p2.ebuild 7242 RMD160 fe9820488677a716d693979be57cbc57f44f8049 SHA1 8b811a82129849fa2633633d4a47878be2c0b44d SHA256 cb357fc0589a09af61868fedcfc31dad70df8278a5ef78a1cd23ae96170ded9e +MISC ChangeLog 35402 RMD160 f5e54cb4ce36293398ea60b0fc020b41a1454469 SHA1 cba256081076df55f585b9c3553df01b0335e2c2 SHA256 b3f139564f0711ca58396cf64c61d26c305efc93e2ae4ca563c336c85ac10495 MISC metadata.xml 500 RMD160 b5ad909ab2b12acd20e78039e33fda0a27383c9e SHA1 2fc5cee8e105e75a251195254c96085a0f3fa9a3 SHA256 e9e4edcf7671391ee2f2af0917a75fc07883f1401aaa22b72dd0133bef81601c -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (GNU/Linux) -iEYEARECAAYFAk+bRFwACgkQvFcC4BYPU0qBkgCgknh8eUyOz9lp7X9mM9c6EdeY -tzwAnAiKKrZ64ZWbtc/GQ+pHIZ1ugm/1 -=jdp9 +iQIcBAEBAgAGBQJPszZwAAoJELEHsLL7fEFWXqMP/0hasirz3//j0pujZnEsIhyo +pxeuuFrEXrEmQA0UHLdIm8OL9fpez+L/zrEAIBMyp1DaDTyN60QgkDRUcveLle5M +o/bGcVJm5ObbHnyT923W+t+x21IfExr5lTy30lLg9v9xxtUiKu936dNDhqK7XGSz +nqF+rl2Oe/Gq2Vf7UM0i6AL5AajT065YI7yUy8ImhqMha+xnrA9T9xN/Hgx1e+uG +y16CpG8pP3T47utRiIWnZhda2aNaQK4aSHkBPnDbjZD5VZHPM4qntRQz0ImO+LNj +EGSWSs1E3VOjQ+iJLXoINeAV9YGsrYsM2+sYMsjxnc6LbXVHFAhXms1zi8p4bdlU +PSs2Z+Cvqu8+d/hXR4/kJ5Xcc/t9c7atkPMo7hCvTxVObD3ZPndWPrJ5Z1dRZzwL +nkP3huADQPE+azeQbyYjFP0oItH0QTKCOF2JlNBoKxupRd3mxD+JkN4DYUI3aD7t +8yH33mUBOeiTPbFgrZVnVDeHz3rph5lkoAxMSnohcxs5Mn6RqmXfkk/7uI57A3FK +xWxtA+RT+rddlAmsbC0A1NdjkBxVcBlZpAVRGuKiMYOqsdRLMgSUcct7BIvxU4YT +aOAXjTl0DPTR/bLjjWTDHJ9nRdoghOAkFUWt/fpMflIiSVQHduj/bSwi0Pf1cBm7 +u5EsUMA+tFRHEi2ooCbb +=A+NK -----END PGP SIGNATURE----- diff --git a/net-misc/dhcp/dhcp-4.2.3_p2.ebuild b/net-misc/dhcp/dhcp-4.2.3_p2.ebuild new file mode 100644 index 000000000000..ec51f79d6e13 --- /dev/null +++ b/net-misc/dhcp/dhcp-4.2.3_p2.ebuild @@ -0,0 +1,237 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcp/dhcp-4.2.3_p2.ebuild,v 1.1 2012/05/16 05:08:40 vapier Exp $ + +EAPI="4" + +inherit eutils toolchain-funcs + +MY_PV="${PV//_alpha/a}" +MY_PV="${MY_PV//_beta/b}" +MY_PV="${MY_PV//_rc/rc}" +MY_PV="${MY_PV//_p/-P}" +MY_P="${PN}-${MY_PV}" +DESCRIPTION="ISC Dynamic Host Configuration Protocol (DHCP) client/server" +HOMEPAGE="http://www.isc.org/products/DHCP" +SRC_URI="ftp://ftp.isc.org/isc/dhcp/${MY_P}.tar.gz + ftp://ftp.isc.org/isc/dhcp/${MY_PV}/${MY_P}.tar.gz" + +LICENSE="as-is BSD" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd" +IUSE="+client ipv6 kernel_linux ldap selinux +server ssl vim-syntax" + +DEPEND="selinux? ( sec-policy/selinux-dhcp ) + client? ( kernel_linux? ( sys-apps/net-tools ) ) + ldap? ( + net-nds/openldap + ssl? ( dev-libs/openssl ) + )" +RDEPEND="${DEPEND} + vim-syntax? ( app-vim/dhcpd-syntax )" + +S="${WORKDIR}/${MY_P}" + +src_unpack() { + unpack ${A} + # handle local bind hell + cd "${S}"/bind + unpack ./bind.tar.gz +} + +src_prepare() { + # Gentoo patches - these will probably never be accepted upstream + # Fix some permission issues + epatch "${FILESDIR}"/${PN}-3.0-fix-perms.patch + # Enable dhclient to equery NTP servers + epatch "${FILESDIR}"/${PN}-4.0-dhclient-ntp.patch + # resolvconf support in dhclient-script + epatch "${FILESDIR}"/${PN}-4.2.2-dhclient-resolvconf.patch + # Stop downing the interface on Linux as that breaks link daemons + # such as wpa_supplicant and netplug + epatch "${FILESDIR}"/${PN}-3.0.3-dhclient-no-down.patch + epatch "${FILESDIR}"/${PN}-4.2.0-errwarn-message.patch + # Enable dhclient to get extra configuration from stdin + epatch "${FILESDIR}"/${PN}-4.2.2-dhclient-stdin-conf.patch + epatch "${FILESDIR}"/${PN}-4.2.2-nogateway.patch #265531 + + # 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 + sed -i \ + -e "/VERSION=/s:'$: Gentoo-${PR}':" \ + configure || 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 + + if use client && ! use server ; then + sed -i -r \ + -e '/^SUBDIRS/s:\<(dhcpctl|relay|server)\>::g' \ + Makefile.in || die + elif ! use client && use server ; then + sed -i -r \ + -e '/^SUBDIRS/s:\<client\>::' \ + Makefile.in || die + fi + + # 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 + rm -rf doc/ja_JP.eucJP + + # make the bind build work + binddir=${S}/bind + cd "${binddir}" || die + cat <<-EOF > bindvar.tmp + binddir=${binddir} + GMAKE=${MAKE:-gmake} + EOF + epatch "${FILESDIR}"/${PN}-4.2.2-bind-disable.patch + cd bind-*/ + epatch "${FILESDIR}"/${PN}-4.2.2-bind-parallel-build.patch #380717 + epatch "${FILESDIR}"/${PN}-4.2.2-bind-build-flags.patch +} + +src_configure() { + # bind defaults to stupid `/usr/bin/ar` + tc-export AR BUILD_CC + export ac_cv_path_AR=${AR} + + # this is tested for by the bind build system, and can cause trouble + # when cross-building; since dhcp itself doesn't make use of libcap, + # simply disable it. + export ac_cv_lib_cap_cap_set_proc=no + + # Use FHS sane paths ... some of these have configure options, + # but not all, so just do it all here. + local e="/etc/dhcp" r="/var/run/dhcp" l="/var/lib/dhcp" + cat <<-EOF >> includes/site.h + #define _PATH_DHCPD_CONF "${e}/dhcpd.conf" + #define _PATH_DHCLIENT_CONF "${e}/dhclient.conf" + #define _PATH_DHCPD_DB "${l}/dhcpd.leases" + #define _PATH_DHCPD6_DB "${l}/dhcpd6.leases" + #define _PATH_DHCLIENT_DB "${l}/dhclient.leases" + #define _PATH_DHCLIENT6_DB "${l}/dhclient6.leases" + #define _PATH_DHCPD_PID "${r}/dhcpd.pid" + #define _PATH_DHCPD6_PID "${r}/dhcpd6.pid" + #define _PATH_DHCLIENT_PID "${r}/dhcpclient.pid" + #define _PATH_DHCLIENT6_PID "${r}/dhcpclient6.pid" + #define _PATH_DHCRELAY_PID "${r}/dhcrelay.pid" + #define _PATH_DHCRELAY6_PID "${r}/dhcrelay6.pid" + EOF + + econf \ + --enable-paranoia \ + --enable-early-chroot \ + --sysconfdir=${e} \ + $(use_enable ipv6 dhcpv6) \ + $(use_with ldap) \ + $(use ldap && use_with ssl ldapcrypto || echo --without-ldapcrypto) + + # configure local bind cruft. symtable option requires + # perl and we don't want to require that #383837. + cd bind/bind-*/ || die + eval econf \ + $(sed -n '/ [.].configure /{s:^[^-]*::;s:>.*::;p}' ../Makefile) \ + --disable-symtable \ + --without-make-clean +} + +src_compile() { + # build local bind cruft first + emake -C bind/bind-*/lib/export install + # then build standard dhcp code + emake +} + +src_install() { + emake install DESTDIR="${D}" + + dodoc README RELNOTES doc/{api+protocol,IANA-arp-parameters} + dohtml doc/References.html + + if [[ -e client/dhclient ]] ; then + # move the client to / + dodir /sbin + mv "${D}"/usr/sbin/dhclient "${D}"/sbin/ || die + + exeinto /sbin + if use kernel_linux ; then + newexe "${S}"/client/scripts/linux dhclient-script + else + newexe "${S}"/client/scripts/freebsd dhclient-script + fi + fi + + if [[ -e server/dhcpd ]] ; then + if use ldap ; then + insinto /etc/openldap/schema + doins contrib/ldap/dhcp.* + dosbin contrib/ldap/dhcpd-conf-to-ldap + fi + + newinitd "${FILESDIR}"/dhcpd.init5 dhcpd + newconfd "${FILESDIR}"/dhcpd.conf2 dhcpd + newinitd "${FILESDIR}"/dhcrelay.init3 dhcrelay + newconfd "${FILESDIR}"/dhcrelay.conf dhcrelay + newinitd "${FILESDIR}"/dhcrelay.init3 dhcrelay6 + newconfd "${FILESDIR}"/dhcrelay6.conf dhcrelay6 + fi + + # the default config files aren't terribly useful #384087 + sed -i '/^[^#]/s:^:#:' "${D}"/etc/dhcp/*.conf || die +} + +pkg_preinst() { + enewgroup dhcp + enewuser dhcp -1 -1 /var/lib/dhcp dhcp + + # Keep the user files over the sample ones. The + # hashing is to ignore the crappy defaults #384087. + local f h + for f in dhclient:da7c8496a96452190aecf9afceef4510 dhcpd:10979e7b71134bd7f04d2a60bd58f070 ; do + h=${f#*:} + f="/etc/dhcp/${f%:*}.conf" + if [ -e "${ROOT}"${f} ] ; then + case $(md5sum "${ROOT}"${f}) in + ${h}*) ;; + *) cp -p "${ROOT}"${f} "${D}"${f};; + esac + fi + done +} + +pkg_postinst() { + 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 +} diff --git a/net-misc/dhcp/files/dhcrelay.init3 b/net-misc/dhcp/files/dhcrelay.init3 new file mode 100755 index 000000000000..277a844708f2 --- /dev/null +++ b/net-misc/dhcp/files/dhcrelay.init3 @@ -0,0 +1,29 @@ +#!/sbin/runscript +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcp/files/dhcrelay.init3,v 1.1 2012/05/16 05:08:40 vapier Exp $ + +depend() { + need net + use logger +} + +start() { + if [ -z "${DHCRELAY_SERVERS}" ]; then + eerror "No DHCRELAY_SERVERS specified in /etc/conf.d/${SVCNAME}" + return 1 + fi + + checkpath -d /var/run/dhcp + + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start --exec /usr/sbin/dhcrelay \ + -- -q $(printf -- '-i %s ' ${IFACE}) ${DHCRELAY_OPTS} ${DHCRELAY_SERVERS} + eend $? +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop --pidfile /var/run/dhcp/${SVCNAME}.pid + eend $? +} diff --git a/net-misc/dhcp/files/dhcrelay6.conf b/net-misc/dhcp/files/dhcrelay6.conf new file mode 100644 index 000000000000..19353e8b57ed --- /dev/null +++ b/net-misc/dhcp/files/dhcrelay6.conf @@ -0,0 +1,14 @@ +# /etc/conf.d/dhcrelay: config file for /etc/init.d/dhcrelay + +# Configure which interface or interfaces to for dhcrelay to listen on +# and send to. +# List all interfaces space separated. If this is not specified then +# we use all interfaces. +#IFACE="" + +# Insert any other options needed. See dhcrelay(8) for details. +# Make sure you specify the lower (-l)/upper (-u) interfaces. +DHCRELAY_OPTS="-6 -l lower-iface -u upper-iface" + +# Space separated list of IPs to forward BOOTP/DHCP packets to. +DHCRELAY_SERVERS="" |