# $Id$ PNAME="dhcpcd" PVER="7.0.1" PBUILD="r1" PCAT="net-misc" DESCRIPTION="dhcpcd is an implementation of the DHCP client specified in RFC2131." HOMEPAGE="http://roy.marples.name/projects/dhcpcd/" DEPEND=">= virtual/glibc" PROVIDE="virtual/dhcp" SRCFILE="${PNAME}-${PVER}.tar.xz" SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" sminclude mtools SRC_URI=( http://roy.marples.name/downloads/${PNAME}/${SRCFILE} mirror://${PNAME}/${SRCFILE} ) UP2DATE="updatecmd http://roy.marples.name/downloads/${PNAME}/ | grep '${PNAME}-[0-9]' | highesttarball xz" src_prepare() { munpack ${SRCFILE} || die cd ${SRCDIR} # disable zeroconf support # we don't want get an automatic ip, only if really requested cat >> dhcpcd.conf << EOF # disabled zeroconf support - we don't want to get an APIPA-address automatically noipv4ll EOF # fix /var/run -> /run sed -i 's:/var/run:/run:g' \ hooks/50-yp.conf \ hooks/dhcpcd-run-hooks.in \ || die } src_compile() { cd ${SRCDIR} mconfigure \ --libexecdir=/usr/lib/dhcpcd \ --localstatedir=/var \ --rundir=/run \ --dbdir=/var/lib/dhcpcd \ --with-hook=ntp.conf \ --with-hook=yp.conf \ --with-hook=dhcpcd-compat \ || die mmake || die } src_install() { cd ${SRCDIR} mmake DESTDIR=${BINDIR} install || die # create dhcpcd status dir mkeepdir /var/run/dhcpcd || die mkeepdir /var/lib/dhcpcd || die # create an empty ntp.conf to shutup warnings memptyfile /etc/ntp.conf || die minstalldocs ChangeLog || die }