# Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit flag-o-matic eutils DESCRIPTION="A DHCP client only" HOMEPAGE="http://developer.berlios.de/projects/dhcpcd/" SRC_URI="http://download.berlios.de/${PN}/${P}.tar.bz2" LICENSE="GPL-2" SLOT="0" KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" IUSE="build debug static" DEPEND="" PROVIDE="virtual/dhcpc" pkg_setup() { if use debug ; then ewarn "WARNING: dhcpcd will provide good debugging output with the" ewarn "debug USE flag enabled but will not actually configure the" ewarn "interface or setup /etc/resolv.conf" fi } src_unpack() { unpack ${A} cd "${S}" # Redefine the location of ntp.drift sed -i 's:/etc/ntp\.drift:/var/lib/ntp/ntp.drift:' src/dhcpconfig.c epatch "${FILESDIR}/${PN}-2.0.5_sname-signedness.patch" epatch "${FILESDIR}/${PN}-2.0.5_implicit-strcmp.patch" #epatch "${FILESDIR}/${P}_bug137478.patch" epatch "${FILESDIR}/${P}_bug137800.patch" } src_compile() { use static && append-flags -static use ppc && replace-flags -O3 -O2 econf $(use_enable debug) || die emake || die } src_install() { into / dosbin src/dhcpcd || die if ! use build ; then dodoc AUTHORS ChangeLog NEWS README doman src/dhcpcd.8 fi }