/[gentoo-x86]/net-misc/dhcp/dhcp-3.0_p2-r4.ebuild
Gentoo

Contents of /net-misc/dhcp/dhcp-3.0_p2-r4.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (hide annotations) (download)
Mon Mar 8 23:45:35 2004 UTC (15 years, 10 months ago) by seemant
Branch: MAIN
Forced a version bump on these ebuilds.  Basically -r0 is now -r4, -r2 is now -r5 and -r3 is now -r6.  The reason for the revision bump was to make this package PROVIDE virtual/dhcp.  Closes a long-standing bloat-reduction request made on gentoo-dev mailing list by:  William Hubbs <kc5eiv@kc5eiv.homeip.net> at http://article.gmane.org/gmane.linux.gentoo.devel/11579

1 seemant 1.1 # Copyright 1999-2004 Gentoo Technologies, Inc.
2     # Distributed under the terms of the GNU General Public License v2
3     # $Header: /home/cvsroot/gentoo-x86/net-misc/dhcp/dhcp-3.0_p2.ebuild,v 1.7 2004/01/15 01:04:44 max Exp $
4    
5     IUSE=""
6    
7     inherit flag-o-matic
8    
9     #This should be fairly consistant now, unless we have any _pre releases...
10     MY_P="${P/_p/pl}"
11     S=${WORKDIR}/${MY_P}
12     DESCRIPTION="ISC Dynamic Host Configuration Protocol"
13     SRC_URI="ftp://ftp.isc.org/isc/dhcp/${MY_P}.tar.gz"
14     HOMEPAGE="http://www.isc.org/products/DHCP"
15    
16     SLOT="0"
17     LICENSE="isc-dhcp"
18     KEYWORDS="x86 ppc sparc ~mips amd64"
19    
20     RDEPEND="virtual/glibc"
21     DEPEND="${RDEPEND}
22     sys-apps/groff"
23    
24     PROVIDE="virtual/dhcpc"
25    
26     src_unpack() {
27     unpack ${A}
28    
29     cd ${S}
30     epatch ${FILESDIR}/dhclient.c-3.0-dw-cli-fix.patch
31    
32     cd ${S}/includes
33     cat <<- END >> site.h
34     #define _PATH_DHCPD_CONF "/etc/dhcp/dhcpd.conf"
35     #define _PATH_DHCLIENT_DB "/var/lib/dhcp/dhclient.leases"
36     #define _PATH_DHCPD_DB "/var/lib/dhcp/dhcpd.leases"
37     END
38     }
39    
40     src_compile() {
41     # 01/Mar/2003: Fix for bug #11960 by Jason Wever <weeve@gentoo.org>
42     # start fix
43     if [ ${ARCH} = "sparc" ]
44     then
45     filter-flags "-O3"
46     filter-flags "-O2"
47     filter-flags "-O"
48     fi
49     # end fix
50     cat <<- END > site.conf
51     CC = gcc ${CFLAGS}
52     ETC = /etc/dhcp
53     VARDB = /var/lib/dhcp
54     ADMMANDIR = /usr/share/man/man8
55     FFMANDIR = /usr/share/man/man5
56     LIBMANDIR = /usr/share/man/man3
57     END
58     ./configure --with-nsupdate || die
59     emake || die
60     }
61    
62     src_install() {
63     dodir /var/lib/dhcp
64     touch ${D}/var/lib/dhcp/dhclient.leases
65     touch ${D}/var/lib/dhcp/dhcpd.leases
66    
67     cd ${S}/work.linux-2.2/client
68     into / ; dosbin dhclient
69     doman *.5 *.8
70    
71     cd ../dhcpctl ; dolib libdhcpctl.a ; doman *.3
72     insinto /usr/include ; doins dhcpctl.h
73    
74     cd ../omapip ; dolib libomapi.a ; doman *.3
75     cd ../relay ; dosbin dhcrelay ; doman *.8
76     cd ../common ; doman *.5
77     cd ../server ; dosbin dhcpd ; doman *.5 *.8
78    
79     cd ${S}/client
80     # admins might wanna edit dhclient-script, so /etc is proper for it.
81     dosed "s:/etc/dhclient-script:/etc/dhcp/dhclient-script:" dhclient.conf
82     insinto /etc/dhcp ; newins dhclient.conf dhclient.conf.sample
83     exeinto /etc/dhcp ; newexe scripts/linux dhclient-script.sample
84    
85     cd ${S}/server
86     insinto /etc/dhcp ; newins dhcpd.conf dhcpd.conf.sample
87    
88     cd ${S}/includes/omapip
89     insinto /usr/include/omapip ; doins alloc.h buffer.h omapip.h
90    
91     cd ${S}/includes/isc-dhcp
92     insinto /usr/include/isc-dhcp
93     doins boolean.h dst.h int.h lang.h list.h result.h types.h
94    
95     cd ${S}
96     dodoc ANONCVS CHANGES COPYRIGHT README RELNOTES
97     newdoc client/dhclient.conf dhclient.conf.sample
98     newdoc client/scripts/linux dhclient-script.sample
99     newdoc server/dhcpd.conf dhcpd.conf.sample
100     docinto doc ; dodoc doc/*
101    
102     insinto /etc/conf.d
103     newins ${FILESDIR}/conf.dhcpd dhcp
104    
105     exeinto /etc/init.d
106     newexe ${FILESDIR}/dhcp.rc7 dhcp
107     }

  ViewVC Help
Powered by ViewVC 1.1.20