2 Summary(pl): Serwer DHCP
9 Group: Networking/Daemons
10 Group(de): Netzwerkwesen/Server
11 Group(pl): Sieciowe/Serwery
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
19 Prereq: rc-scripts >= 0.2.0
20 Prereq: /sbin/chkconfig
21 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24 DHCP (Dynamic Host Configuration Protocol) is a protocol which allows
25 individual devices on an IP network to get their own network
26 configuration information (IP address, subnetmask, broadcast address,
27 etc.) from a DHCP server. The overall purpose of DHCP is to make it
28 easier to administer a large network.
31 Serwer DHCP (Dynamic Host Configuration Protocol).
33 DHCP to protokó³ pozwalaj±cy urz±dzeniom pracuj±cym w sieci IP na
34 pobieranie ich konfiguracji IP (adresu, maski podsieci, adresu
35 rozg³oszeniowego itp.) z serwera DHCP. U³atwia on administrowanie
40 Summary(pl): Klient DHCP
41 Group: Networking/Daemons
42 Group(de): Netzwerkwesen/Server
43 Group(pl): Sieciowe/Serwery
47 Dynamic Host Configuration Protocol Client.
49 %description -l pl client
50 Klient DHCP (Dynamic Host Configuration Protocol).
53 Summary: DHCP Relay Agent
54 Summary(pl): Agent przekazywania informacji DHCP
55 Group: Networking/Daemons
56 Group(de): Netzwerkwesen/Server
57 Group(pl): Sieciowe/Serwery
58 Prereq: rc-scripts >= 0.2.0
59 Prereq: /sbin/chkconfig
62 Dhcp relay is a relay agent for DHCP packets. It is used on a subnet
63 with DHCP clients to "relay" their requests to a subnet that has a
64 DHCP server on it. Because DHCP packets can be broadcast, they will
65 not be routed off of the local subnet. The DHCP relay takes care of
68 %description -l pl relay
69 Agent przekazywania DHCP (Dynamic Host Configuration Protocol) miêdzy
70 podsieciami. Poniewa¿ komunikaty DHCP mog± byæ przekazywane w formie
71 rozg³oszeniowej, bez tego agenta nie zostan± przerutowane do innej
79 # Notice: this is not autoconf configure!!!!!!!
80 # do not change it to %%configure
83 %{__make} COPTS="%{rpmcflags} \
84 -D_PATH_DHCPD_DB=\\\"/var/lib/%{name}/dhcpd.leases\\\" \
85 -D_PATH_DHCLIENT_DB=\\\"/var/lib/%{name}/dhclient.leases\\\"" \
86 DEBUG="" VARDB="/var/lib/%{name}"
89 rm -rf $RPM_BUILD_ROOT
90 install -d $RPM_BUILD_ROOT{/sbin,%{_sbindir},%{_bindir},%{_mandir}/man{5,8}} \
91 $RPM_BUILD_ROOT{/var/lib/%{name},%{_sysconfdir}/{rc.d/init.d,sysconfig}}
94 DESTDIR="$RPM_BUILD_ROOT" \
95 CLIENTBINDIR="/sbin" \
96 BINDIR="%{_sbindir}" \
97 ADMMANDIR="%{_mandir}/man8" \
99 FFMANDIR="%{_mandir}/man5" \
100 VARDB="/var/lib/%{name}" \
103 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/dhcpd
104 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/dhcp-relay
105 install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/dhcp-relay
106 install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/dhcpd
108 install client/scripts/linux $RPM_BUILD_ROOT%{_sysconfdir}/dhclient-script
110 gzip -9nf doc/* README RELNOTES
112 touch $RPM_BUILD_ROOT/var/lib/%{name}/{dhcpd,dhclient}.leases
115 rm -rf $RPM_BUILD_ROOT
118 /sbin/chkconfig --add dhcpd
119 touch /var/lib/%{name}/dhcpd.leases
121 if [ ! -d /var/lib/dhcp ]; then
122 install -d /var/lib/dhcp
125 if [ -f /var/lock/subsys/dhcpd ]; then
126 /etc/rc.d/init.d/dhcpd restart >&2
128 echo "Run \"/etc/rc.d/init.d/dhcpd start\" to start dhcpd daemon."
132 /sbin/chkconfig --add dhcp-relay
133 if [ -f /var/lock/subsys/dhcrelay ]; then
134 mv /var/lock/subsys/dhcrelay /var/lock/subsys/dhcp-relay
136 if [ -f /var/lock/subsys/dhcp-relay ]; then
137 /etc/rc.d/init.d/dhcp-relay restart >&2
139 echo "Run \"/etc/rc.d/init.d/dhcp-relay start\" to start dhcrelay daemon."
143 if [ -d /var/lib/dhcp ]; then
144 install -d /var/lib/dhcp
148 if [ "$1" = "0" ];then
149 if [ -f /var/lock/subsys/dhcpd ]; then
150 /etc/rc.d/init.d/dhcpd stop >&2
152 /sbin/chkconfig --del dhcpd
156 if [ "$1" = "0" ];then
157 if [ -f /var/lock/subsys/dhcp-relay ]; then
158 /etc/rc.d/init.d/dhcp-relay stop >&2
160 /sbin/chkconfig --del dhcp-relay
163 %triggerpostun -- dhcp < 3.0
164 if [ `grep ddns-update-style /etc/dhcpd.conf` = "" ]; then
165 echo "ddns-update-style none;" > /etc/dhcpd.conf.tmp
166 echo "" >> /etc/dhcpd.conf.tmp
167 cat /etc/dhcpd.conf >>/etc/dhcpd.conf.tmp
168 mv -f /etc/dhcpd.conf.tmp /etc/dhcpd.conf
172 %defattr(644,root,root,755)
173 %doc doc/* README.gz RELNOTES.gz dhcpd.conf.sample
174 %{_mandir}/man5/dhcp*
175 %{_mandir}/man8/dhcp*
176 %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/dhcpd
177 %attr(755,root,root) %{_sbindir}/dhcpd
178 %attr(754,root,root) /etc/rc.d/init.d/dhcpd
179 %attr(750,root,root) %dir /var/lib/%{name}
180 %ghost /var/lib/%{name}/dhcpd.leases
183 %defattr(644,root,root,755)
184 %attr(755,root,root) /sbin/dhclient
185 %attr(755,root,root) %{_sysconfdir}/dhclient-script
186 %{_mandir}/man[58]/dhclient*
187 %ghost /var/lib/%{name}/dhclient.leases
190 %defattr(644,root,root,755)
191 %{_mandir}/man8/dhcrelay*
192 %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/dhcp-relay
193 %attr(755,root,root) %{_sbindir}/dhcrelay
194 %attr(754,root,root) /etc/rc.d/init.d/dhcp-relay