SPECS: avahi.spec - added init scripts

freetz freetz at pld-linux.org
Sat Jan 21 14:35:26 CET 2006


Author: freetz                       Date: Sat Jan 21 13:35:26 2006 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- added init scripts

---- Files affected:
SPECS:
   avahi.spec (1.1 -> 1.2) 

---- Diffs:

================================================================
Index: SPECS/avahi.spec
diff -u SPECS/avahi.spec:1.1 SPECS/avahi.spec:1.2
--- SPECS/avahi.spec:1.1	Sat Jan 21 14:02:45 2006
+++ SPECS/avahi.spec	Sat Jan 21 14:35:21 2006
@@ -12,6 +12,8 @@
 Group:		Applications
 Source0:	http://avahi.org/download/%{name}-%{version}.tar.gz
 # Source0-md5:	12eb941043f26f82c51e99821ac52c44
+Source1:	%{name}-daemon
+Source2:	%{name}-dnsconfd
 URL:		http://avahi.org/
 BuildRequires:	autoconf
 BuildRequires:	automake
@@ -250,28 +252,32 @@
 
 %install
 rm -rf $RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
 
 %{__make} install \
 	DESTDIR=$RPM_BUILD_ROOT \
 	pythondir=%{py_sitedir}
-	
+
+install %{SOURCE1} %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d
+
 #rm -f $RPM_BUILD_ROOT%{py_sitedir}/avahi/*.py
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
-# finish init
-%if 0
 %post
-/sbin/chkconfig --add %{name}
-%service %{name} restart
+/sbin/chkconfig --add %{name}-daemon
+%service %{name}-daemon restart
+/sbin/chkconfig --add %{name}-dnsconfd
+%service %{name}-dnsconfd restart
 
 %preun
 if [ "$1" = "0" ]; then
-	%service -q %{name} stop
-	/sbin/chkconfig --del %{name}
+	%service -q %{name}-dnsconfd stop
+	/sbin/chkconfig --del %{name}-dnsconfd
+	%service -q %{name}-daemon stop
+	/sbin/chkconfig --del %{name}-daemon
 fi
-%endif
 
 %post	libs -p /sbin/ldconfig
 %postun	libs -p /sbin/ldconfig
@@ -310,11 +316,8 @@
 
 %{_mandir}/man*/*
 
-# finish init
-%if 0
-%attr(754,root,root) /etc/rc.d/init.d/%{name}
-%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/%{name}
-%endif
+%attr(754,root,root) /etc/rc.d/init.d/%{name}-daemon
+%attr(754,root,root) /etc/rc.d/init.d/%{name}-dnsconfd
 
 %files libs
 %defattr(644,root,root,755)
@@ -406,6 +409,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.2  2006/01/21 13:35:21  freetz
+- added init scripts
+
 Revision 1.1  2006/01/21 13:02:45  freetz
 - started work on Avahi for PLD
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/avahi.spec?r1=1.1&r2=1.2&f=u



More information about the pld-cvs-commit mailing list