2 Summary(pl): Serwer DHCP
7 Group: Networking/Daemons
8 Group(de): Netzwerkwesen/Server
9 Group(pl): Sieciowe/Serwery
10 Copyright: distributable
12 Source0: ftp://ftp.isc.org/isc/dhcp/%{name}-%{version}.tar.gz
14 Source2: %{name}-relay.init
15 Source3: %{name}-relay.sysconfig
16 Source4: %{name}d.conf.sample
17 Source5: %{name}.sysconfig
18 Patch0: %{name}-libbind.patch
20 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21 Prereq: /sbin/chkconfig
22 BuildRequires: bind-devel
23 Requires: rc-scripts >= 0.2.0
26 DHCP (Dynamic Host Configuration Protocol) is a protocol which allows
27 individual devices on an IP network to get their own network
28 configuration information (IP address, subnetmask, broadcast address,
29 etc.) from a DHCP server. The overall purpose of DHCP is to make it
30 easier to administer a large network.
33 Serwer DHCP (Dynamic Host Configuration Protocol).
37 Summary(pl): Klient DHCP
38 Group: Networking/Daemons
39 Group(de): Netzwerkwesen/Server
40 Group(pl): Sieciowe/Serwery
44 Dynamic Host Configuration Protocol Client.
46 %description -l pl client
47 Klient DHCP (Dynamic Host Configuration Protocol).
50 Summary: DHCP Relay Agent
51 Summary(pl): Agent przekazywania informacji DHCP
52 Group: Networking/Daemons
53 Group(de): Netzwerkwesen/Server
54 Group(pl): Sieciowe/Serwery
55 Requires: rc-scripts >= 0.2.0
58 Dhcp relay is a relay agent for DHCP packets. It is used on a subnet
59 with DHCP clients to "relay" their requests to a subnet that has a
60 DHCP server on it. Because DHCP packets can be broadcast, they will
61 not be routed off of the local subnet. The DHCP relay takes care of
64 %description -l pl relay
65 Agent przekazywania DHCP (Dynamic Host Configuration Protocol) miêdzy
75 LDFLAGS="-L%{_libdir}/lib/bind/lib" ; export LDFLAGS
76 # Notice: this is not autoconf configure!!!!!!!
77 # do not change it to %configure
78 ./configure --with-nsupdate
80 %{__make} COPTS="$RPM_OPT_FLAGS -D_PATH_DHCPD_DB=\\\"/var/lib/%{name}/dhcpd.leases\\\" \
81 -D_PATH_DHCLIENT_DB=\\\"/var/lib/%{name}/dhclient.leases\\\"" \
82 DEBUG="" VARDB="/var/lib/%{name}"
85 rm -rf $RPM_BUILD_ROOT
86 install -d $RPM_BUILD_ROOT{/sbin,%{_sbindir},%{_mandir}/man{5,8}} \
87 $RPM_BUILD_ROOT{/var/lib/%{name},%{_sysconfdir}/{rc.d/init.d,sysconfig}}
90 DESTDIR="$RPM_BUILD_ROOT" \
91 CLIENTBINDIR="/sbin" \
92 BINDIR="%{_sbindir}" \
93 ADMMANDIR="%{_mandir}/man8" \
95 FFMANDIR="%{_mandir}/man5" \
96 VARDB="/var/lib/%{name}" \
99 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/dhcpd
100 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/dhcp-relay
101 install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/dhcp-relay
102 install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/dhcpd
104 install client/scripts/linux $RPM_BUILD_ROOT%{_sysconfdir}/dhclient-script
106 gzip -9nf doc/* README RELNOTES
108 touch $RPM_BUILD_ROOT/var/lib/%{name}/{dhcpd,dhclient}.leases
111 /sbin/chkconfig --add dhcpd
112 touch /var/lib/%{name}/dhcpd.leases
114 if [ ! -d /var/lib/dhcp ]; then
115 install -d /var/lib/dhcp
118 if [ -f /var/lock/subsys/dhcpd ]; then
119 /etc/rc.d/init.d/dhcpd restart >&2
121 echo "Run \"/etc/rc.d/init.d/dhcpd start\" to start dhcpd daemon."
125 /sbin/chkconfig --add dhcrelay
127 if [ -f /var/lock/subsys/dhcrelay ]; then
128 /etc/rc.d/init.d/dhcrelay restart >&2
130 echo "Run \"/etc/rc.d/init.d/dhcrelay start\" to start dhcrelay daemon."
134 if [ -d /var/lib/dhcp ]; then
135 install -d /var/lib/dhcp
139 if [ "$1" = "0" ];then
140 if [ -f /var/lock/subsys/dhcpd ]; then
141 /etc/rc.d/init.d/dhcpd stop >&2
143 /sbin/chkconfig --del dhcpd
147 if [ "$1" = "0" ];then
148 if [ -f /var/lock/subsys/dhcrelay ]; then
149 /etc/rc.d/init.d/dhrelay stop >&2
151 /sbin/chkconfig --del dhcrelay
155 rm -rf $RPM_BUILD_ROOT
158 %defattr(644,root,root,755)
159 %doc doc/* README.gz RELNOTES.gz dhcpd.conf.sample
160 %{_mandir}/man5/dhcp*
161 %{_mandir}/man8/dhcp*
162 %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/dhcpd
163 %attr(755,root,root) %{_sbindir}/dhcpd
164 %attr(754,root,root) /etc/rc.d/init.d/dhcpd
165 %attr(750,root,root) %dir /var/lib/%{name}
166 %ghost /var/lib/%{name}/dhcpd.leases
169 %defattr(644,root,root,755)
170 %attr(755,root,root) /sbin/dhclient
171 %attr(755,root,root) %{_sysconfdir}/dhclient-script
172 %{_mandir}/man[58]/dhclient*
173 %ghost /var/lib/%{name}/dhclient.leases
176 %defattr(644,root,root,755)
177 %{_mandir}/man8/dhcrelay*
178 %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/dhcp-relay
179 %attr(755,root,root) %{_sbindir}/dhcrelay
180 %attr(754,root,root) /etc/rc.d/init.d/dhcp-relay