]> git.pld-linux.org Git - packages/dhcp.git/blobdiff - dhcp.spec
- updated to final 3.0 (Epoch: 2).
[packages/dhcp.git] / dhcp.spec
index 42516b796208db98f16bae7976d8ea58b3272de6..c8780ec030912d146823dd1ed3a0456263cafa73 100644 (file)
--- a/dhcp.spec
+++ b/dhcp.spec
@@ -1,14 +1,14 @@
 Summary:       DHCP Server 
 Summary(pl):   Serwer DHCP 
 Name:          dhcp
-Version:       3.0rc10
+Version:       3.0
 Release:       1
-Epoch:         1
+Epoch:         2
 Vendor:                ISC
+License:       Distributable
 Group:         Networking/Daemons
 Group(de):     Netzwerkwesen/Server
 Group(pl):     Sieciowe/Serwery
-Copyright:     distributable
 Source0:       ftp://ftp.isc.org/isc/dhcp/%{name}-%{version}.tar.gz
 Source1:       %{name}.init
 Source2:       %{name}-relay.init
@@ -17,6 +17,7 @@ Source4:      %{name}d.conf.sample
 Source5:       %{name}.sysconfig
 BuildRequires: groff
 Prereq:                rc-scripts >= 0.2.0
+Prereq:                /sbin/chkconfig
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -54,7 +55,8 @@ Summary(pl):  Agent przekazywania informacji DHCP
 Group:         Networking/Daemons
 Group(de):     Netzwerkwesen/Server
 Group(pl):     Sieciowe/Serwery
-Requires:      rc-scripts >= 0.2.0
+Prereq:                rc-scripts >= 0.2.0
+Prereq:                /sbin/chkconfig
 
 %description relay
 Dhcp relay is a relay agent for DHCP packets. It is used on a subnet
@@ -109,6 +111,9 @@ gzip -9nf doc/* README RELNOTES
 
 touch $RPM_BUILD_ROOT/var/lib/%{name}/{dhcpd,dhclient}.leases
 
+%clean
+rm -rf $RPM_BUILD_ROOT
+
 %post
 /sbin/chkconfig --add dhcpd
 touch /var/lib/%{name}/dhcpd.leases
@@ -125,8 +130,10 @@ fi
 
 %post relay
 /sbin/chkconfig --add dhcp-relay
-
 if [ -f /var/lock/subsys/dhcrelay ]; then
+       mv /var/lock/subsys/dhcrelay /var/lock/subsys/dhcp-relay
+fi
+if [ -f /var/lock/subsys/dhcp-relay ]; then
        /etc/rc.d/init.d/dhcp-relay restart >&2
 else
        echo "Run \"/etc/rc.d/init.d/dhcp-relay start\" to start dhcrelay daemon."
@@ -147,14 +154,19 @@ fi
 
 %preun relay
 if [ "$1" = "0" ];then
-       if [ -f /var/lock/subsys/dhcrelay ]; then
+       if [ -f /var/lock/subsys/dhcp-relay ]; then
                /etc/rc.d/init.d/dhcp-relay stop >&2
        fi
        /sbin/chkconfig --del dhcp-relay
 fi
 
-%clean
-rm -rf $RPM_BUILD_ROOT
+%triggerpostun -- dhcp < 3.0
+if [ `grep ddns-update-style /etc/dhcpd.conf` = "" ]; then
+       echo "ddns-update-style none;" > /etc/dhcpd.conf.tmp
+       echo "" >> /etc/dhcpd.conf.tmp
+       cat /etc/dhcpd.conf >>/etc/dhcpd.conf.tmp
+       mv -f /etc/dhcpd.conf.tmp /etc/dhcpd.conf
+fi
 
 %files
 %defattr(644,root,root,755)
This page took 0.069007 seconds and 4 git commands to generate.