SPECS: rsync.spec - use %service

glen glen at pld-linux.org
Tue Mar 14 02:10:12 CET 2006


Author: glen                         Date: Tue Mar 14 01:10:12 2006 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- use %service

---- Files affected:
SPECS:
   rsync.spec (1.107 -> 1.108) 

---- Diffs:

================================================================
Index: SPECS/rsync.spec
diff -u SPECS/rsync.spec:1.107 SPECS/rsync.spec:1.108
--- SPECS/rsync.spec:1.107	Sun Mar 12 09:57:19 2006
+++ SPECS/rsync.spec	Tue Mar 14 02:10:04 2006
@@ -27,11 +27,12 @@
 Patch0:		%{name}-config.patch
 Patch1:		%{name}-man.patch
 URL:		http://rsync.samba.org/
+BuildRequires:	acl-devel
 BuildRequires:	autoconf >= 2.52
 BuildRequires:	automake
-BuildRequires:	acl-devel
 BuildRequires:	openssl-devel
 BuildRequires:	popt-devel
+BuildRequires:	rpmbuild(macros) >= 1.268
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %define		_sysconfdir	/etc/rsyncd
@@ -98,8 +99,8 @@
 Summary:	Files necessary to run rsync in daemon mode
 Summary(pl):	Pliki niezbędne do uruchomienia rsynca w trybie serwera
 Group:		Networking/Daemons
-PreReq:		rc-inetd
 Requires:	%{name} = %{version}-%{release}
+Requires:	rc-inetd
 Provides:	rsyncd
 Obsoletes:	rsyncd
 Obsoletes:	rsyncd-standalone
@@ -212,30 +213,20 @@
 rm -rf $RPM_BUILD_ROOT
 
 %post -n rsyncd-inetd
-if [ -f /var/lock/subsys/rc-inetd ]; then
-	/etc/rc.d/init.d/rc-inetd restart 1>&2
-else
-	echo "Type \"/etc/rc.d/init.d/rc-inetd start\" to start inet server" 1>&2
-fi
+%service -q rc-inetd reload
 
 %postun -n rsyncd-inetd
-if [ "$1" = "0" -a -f /var/lock/subsys/rc-inetd ]; then
-	/etc/rc.d/init.d/rc-inetd reload 1>&2
+if [ "$1" = "0" ]; then
+	%service -q rc-inetd reload
 fi
 
 %post -n rsyncd-standalone
 /sbin/chkconfig --add rsyncd
-if [ -f /var/lock/subsys/rsyncd ]; then
-	/etc/rc.d/init.d/rsyncd restart 1>&2
-else
-	echo "Type \"/etc/rc.d/init.d/rsyncd start\" to start rsync server" 1>&2
-fi
+%service rsyncd restart "rsync server"
 
 %preun -n rsyncd-standalone
 if [ "$1" = "0" ]; then
-	if [ -f /var/lock/subsys/rsyncd ]; then
-		/etc/rc.d/init.d/rsyncd stop 1>&2
-	fi
+	%service rsyncd stop
 	/sbin/chkconfig --del rsyncd
 fi
 
@@ -273,6 +264,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.108  2006/03/14 01:10:04  glen
+- use %service
+
 Revision 1.107  2006/03/12 08:57:19  qboosh
 - tests bcond desc
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/rsync.spec?r1=1.107&r2=1.108&f=u



More information about the pld-cvs-commit mailing list