net-misc/dhcp: add new version of the 4.1 release

(Portage version: 2.2.0_alpha19-r1/svn/Linux x86_64)

git-svn-id: https://svn.disconnected-by-peer.at/svn/linamh/trunk/mds@2825 6952d904-891a-0410-993b-d76249ca496b
This commit is contained in:
geos_one 2011-01-30 14:20:54 +00:00
parent 0e9d2baedb
commit 6664156096
3 changed files with 232 additions and 2 deletions

View File

@ -1,7 +1,12 @@
# ChangeLog for net-misc/dhcp
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcp/ChangeLog,v 1.154 2009/05/29 23:30:28 vapier Exp $
*dhcp-4.1.2_p1 (30 Jan 2011)
30 Jan 2011; Mario Fetka <mario.fetka@gmail.com> +dhcp-4.1.2_p1.ebuild:
add new version of the 4.1 release
*dhcp-4.2.0_p2 (31 Dec 2010)
31 Dec 2010; Mario Fetka <mario.fetka@gmail.com> dhcp-3.1.2.ebuild,

View File

@ -52,6 +52,7 @@ DIST dhcp-4.0.2.tar.gz 1043137 RMD160 7c80370b433de30f89c8e685a939a89e5390ead7 S
DIST dhcp-4.1.0.tar.gz 1086815 RMD160 bf96fa9d135a65b4d9b27f8caf4f3744f0636c80 SHA1 46e161892140a3b60cd56e62b442f48f51bc605f SHA256 688741e970410efdb177513550f8cd1ee52032eb109313ab316a852f40310914
DIST dhcp-4.1.1-P1.tar.gz 1085414 RMD160 d963e87a24e4dd8f98002577446169773a0b8422 SHA1 e9e756df09502f6666cd79bdf0ab3af0f92b41b0 SHA256 2f640350cbb1966ec3090198c3f128d649a3655f747f96ce910a477fe63263da
DIST dhcp-4.1.1.tar.gz 1084368 RMD160 8b5b7223979c2bf279fe8042ad97680f1d2205fe SHA1 b23a28d481a84248f8170b4c6c1166a86c04b2a6 SHA256 37058685bffbfeb793cfb0867f0b1911f8d238ea69fbaa6cbb165455ab803618
DIST dhcp-4.1.2-P1.tar.gz 1092661 RMD160 f57c3a4b0cbbbd8fdc0543d12266fff63f175ceb SHA1 d682f8d1d2905432550864c3cd79eeb29607d6b5 SHA256 bf6e13e1aa90c4d15adb6fdf0071b3da8988c3322c1b5629075181eea9d78dcd
DIST dhcp-4.1.2.tar.gz 1092220 RMD160 2616df849354a63ffa269d1e12714f1ee55c3b62 SHA1 99054d38b957a917c9bfb5c135c1d3fe38713093 SHA256 82e0f6627a91990870fddac1a1e8e1e076ddf20981cd03d396199f182a714e29
DIST dhcp-4.2.0-P1.tar.gz 8582012 RMD160 d57b68957c200a59052adf4a9706ede9aad97527 SHA1 e4c089d976d73c1e5d15bb6c5aedab1124d61de7 SHA256 5f9c9ea376d3aedbe4c0161176abfe6dbfa649b7f7b2010b8db53f4ff49cc535
DIST dhcp-4.2.0-P2.tar.gz 8579215 RMD160 8ac1f44b193d9c0ffc7fb959cc0e47c084ed7581 SHA1 95de255c22643e67d8aca9aa712fb6113b413ef4 SHA256 11f3a10c2476133739efacccc26e0fc67c1902354493a917c10fe3e4abaa7fba
@ -72,8 +73,9 @@ EBUILD dhcp-4.1.0.ebuild 7488 RMD160 951457f2b70458c38d82c5013e8e6287ab0353fb SH
EBUILD dhcp-4.1.1.ebuild 7028 RMD160 e749ceb20ce4ec53319a5c0b2eb51fbd1a9f6da0 SHA1 f24922e252a1a9dad9972cbabd6aaf88308f4797 SHA256 d4ca9c44e344189290decb3da8375a834b496730f06d59545af19f95bd102e03
EBUILD dhcp-4.1.1_p1.ebuild 6969 RMD160 231066d0ebb33ea454f0874566234080073d5f72 SHA1 b90be96d283dbd983ea67efabbe545380a03fb7a SHA256 f115cdfdf85996d94cab0b30343a474f8a74fc3c31607798e246e42dc249cce6
EBUILD dhcp-4.1.2.ebuild 6856 RMD160 ec3861378f32cca77c68fbbb0886a98129a49399 SHA1 3f0054016582149be39a5f5f2fbaffd96d420a3b SHA256 13a95298e1e54d623ff5769228a94fcc533bc59c961e3fae77c318d2978da006
EBUILD dhcp-4.1.2_p1.ebuild 6856 RMD160 a69e9229c8e9b2b1d9e5bb4401216de67e6d39a4 SHA1 2706d24f35dccc7a8f2ea6e0fd96b68521c42081 SHA256 fc4ab4ce8df7bc5ed918f3309dd61c48205a6208665d732878a52de101fb0606
EBUILD dhcp-4.2.0.ebuild 6446 RMD160 ef04d42aae30a41e75b020cce55c29ba7f9308b6 SHA1 d8fda6cb3428cec028d1d1b1f879cbbf97440d88 SHA256 d49b721691f80d55616404d2f47b069a5af04b86664d39a16dda983a03f273e9
EBUILD dhcp-4.2.0_p1.ebuild 6470 RMD160 3cb152aa2e9b374a3785bb662689e2c29b090af6 SHA1 47df78414167bd0a19c8dd8f18a7758ce631fdd1 SHA256 3d5faddc64f8e088c65ec82f5453f0ef18c2f5c2ee254098a726672f215fecda
EBUILD dhcp-4.2.0_p2.ebuild 6371 RMD160 a44086bff7fade134bbf7c6f6b43e28310cab5fd SHA1 8aa8e569af3db13670b56d5a735a44dc0bad9e1f SHA256 48ae1f64d1580aac9c86f36ae45534f7e6c3f4b55befda27a4e846496666cdf9
MISC ChangeLog 30823 RMD160 566b62f0b5cd6d2d7e6cedbdf3293242bad070ff SHA1 50c7205fe6b772fc7daf1f07a592a451de3d2d00 SHA256 d1d302da887e49d36db2a9e0ed42f2737ed906d74353fbf1b497e171948103d1
MISC ChangeLog 30965 RMD160 d481d24f6c5f87e5d6357688366d8be2ea6fdada SHA1 9c34f679faafb531e6826b945eccadf1714a7efc SHA256 64504d0cd96d1f663b79b4e10f722470758f98e61237442da19a1c3cf439b749
MISC metadata.xml 358 RMD160 97ecd4b6ee0a24352a71a66d5ad4fd82481156b4 SHA1 d80da2cf7c6892cdad6b681fda29e46472d68871 SHA256 8665f24cdfcc09576b595f8bd257333ff5f9ea7ee0ca2925ba6fb74d90e12415

View File

@ -0,0 +1,223 @@
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcp/dhcp-4.1.0.ebuild,v 1.2 2010/01/15 19:00:22 ulm Exp $
inherit eutils flag-o-matic autotools
LDAP_PV="4.1.1-2"
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}"
MY_LDAP_PV="${LDAP_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
http://cloud.github.com/downloads/dcantrell/ldap-for-dhcp/ldap-for-dhcp-${LDAP_PV}.tar.gz"
LICENSE="as-is BSD"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~sparc-fbsd ~x86 ~x86-fbsd"
IUSE="doc ipv6 selinux kernel_linux vim-syntax ldap ssl"
DEPEND="selinux? ( sec-policy/selinux-dhcp )
kernel_linux? ( sys-apps/net-tools )
vim-syntax? ( app-vim/dhcpd-syntax )
ldap? ( net-nds/openldap
ssl? ( dev-libs/openssl ) )"
PROVIDE="virtual/dhcpc"
S="${WORKDIR}/${MY_P}"
src_unpack() {
unpack ${A}
cd "${S}"
# 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.1-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
# Quiet the isc blurb
epatch "${FILESDIR}/${PN}"-4.1.1-no_isc_blurb-1.patch
# Enable dhclient to get extra configuration from stdin
epatch "${FILESDIR}/${PN}"-4.0.1-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
# 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
# Ldap patch for dhcp
epatch "${WORKDIR}/ldap-for-dhcp-${LDAP_PV}/dhcp-${MY_LDAP_PV}"-ldap.patch
# Brand the version with Gentoo
# include revision if >0
local newver="Gentoo"
[[ ${PR} != "r0" ]] && newver="${newver}-${PR}"
sed -i "/AC_INIT/s/\(\[[0-9]\+\.[0-9]\+\.[0-9]\+\)/\1-${newver}/" \
configure.ac || 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
# 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
eautoreconf
}
src_compile() {
econf \
--enable-paranoia \
--sysconfdir /etc/dhcp \
--with-cli-pid-file=/var/run/dhcp/dhclient.pid \
--with-cli-lease-file=/var/lib/dhcp/dhclient.leases \
--with-srv-pid-file=/var/run/dhcp/dhcpd.pid \
--with-srv-lease-file=/var/lib/dhcp/dhcpd.leases \
--with-relay-pid-file=/var/run/dhcp/dhcrelay.pid \
$(use_enable ipv6 dhcpv6) \
$(use_with ldap) \
$(use_with ssl ldapcrypto) \
|| die
emake || die "compile problem"
}
src_install() {
for installdir in includes tests common minires dst omapip client dhcpctl relay server; do
cd "${S}/${installdir}"
if [ "${installdir}" == client ]; then
make install DESTDIR="${D}" exec_prefix="" || die
else
make install DESTDIR="${D}" exec_prefix="/usr" || die
fi
done
cd "${S}"
exeinto /sbin
if use kernel_linux; then
newexe "${S}"/client/scripts/linux dhclient-script
else
newexe "${S}"/client/scripts/freebsd dhclient-script
fi
if use doc; then
dodoc README RELNOTES doc/*
use ldap && dodoc "${WORKDIR}/ldap-for-dhcp-${LDAP_PV}"/*.ldap "${WORKDIR}/ldap-for-dhcp-${LDAP_PV}"/draft-ietf-dhc-ldap-schema-01.txt
fi
insinto /etc/dhcp
newins client/dhclient.conf dhclient.conf.sample
keepdir /var/{lib,run}/dhcp
keepdir /var/lib/dhclient
# Install our server files
insinto /etc/dhcp
newins server/dhcpd.conf dhcpd.conf.sample
newinitd "${FILESDIR}"/dhcpd.init2 dhcpd
newinitd "${FILESDIR}"/dhcrelay.init dhcrelay
newconfd "${FILESDIR}"/dhcpd.conf dhcpd
newconfd "${FILESDIR}"/dhcrelay.conf dhcrelay
# install ldap files
if use ldap; then
insinto /etc/openldap/schema
doins "${WORKDIR}/ldap-for-dhcp-${LDAP_PV}"/dhcp.*
dosbin "${WORKDIR}/ldap-for-dhcp-${LDAP_PV}"/dhcpd-conf-to-ldap
fi
# We never want portage to own this file
rm -f "${D}"/var/lib/dhcp/dhcpd.leases
}
pkg_preinst() {
enewgroup dhcp
enewuser dhcp -1 -1 /var/lib/dhcp dhcp
}
pkg_postinst() {
chown -R 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() {
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"
}