]> git.pld-linux.org Git - packages/dhcp-helper.git/commitdiff
- version 0.7
authortommat <tommat@pld-linux.org>
Thu, 27 Jul 2006 11:09:42 +0000 (11:09 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
- added init script and sysconf file

Changed files:
    dhcp-helper.spec -> 1.3

dhcp-helper.spec

index 525d4105659163675ca79a13f0e76bc521bba825..b6255fa5dd8781417f084127700a0f9dd78ed390 100644 (file)
@@ -1,13 +1,18 @@
 Summary:       simple, straightforward DHCP relay agent
 Summary(pl):   prosty, nieskomplikowany DHCP relay
 Name:          dhcp-helper
-Version:       0.2
+Version:       0.7
 Release:       1
 License:       GPL
 Group:         Networking/Daemons
 Source0:       http://thekelleys.org.uk/dhcp-helper/%{name}-%{version}.tar.gz
-# Source0-md5: 2ad69a3388b0750c66cc9da212397a90
+# Source0-md5: 840636145f4b15b92cdca4ad1d6810e9
+Source1:       %{name}.init
+Source2:       %{name}.sysconfig
 URL:           http://thekelleys.org.uk/dhcp-helper/
+BuildRequires: rpmbuild(macros) >= 1.268
+Requires(post,preun):  /sbin/chkconfig
+Requires:      rc-scripts >= 0.2.0
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -27,18 +32,33 @@ alternatywa dla relaya autorstwa ISC.
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT%{_sysconfdir}/{rc.d/init.d,sysconfig}
 
 %{__make} install \
        DESTDIR=$RPM_BUILD_ROOT \
        BINDIR="%{_sbindir}" \
        MANDIR="%{_mandir}"
 
+install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/%{name}
+install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/%{name}
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%post
+/sbin/chkconfig --add dhcp-helper
+%service dhcp-helper restart "dhcp-helper daemon"
+
+%preun
+if [ "$1" = "0" ];then
+       %service dhcp-helper stop
+       /sbin/chkconfig --del dhcp-helper
+fi
+
 %files
 %defattr(644,root,root,755)
 %doc README
+%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/dhcp-helper
+%attr(754,root,root) /etc/rc.d/init.d/dhcp-helper
 %attr(755,root,root) %{_sbindir}/*
 %{_mandir}/man*/*
This page took 0.112914 seconds and 4 git commands to generate.