SPECS: apmud.spec - use %service

glen glen at pld-linux.org
Fri Apr 14 19:40:06 CEST 2006


Author: glen                         Date: Fri Apr 14 17:40:06 2006 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- use %service

---- Files affected:
SPECS:
   apmud.spec (1.4 -> 1.5) 

---- Diffs:

================================================================
Index: SPECS/apmud.spec
diff -u SPECS/apmud.spec:1.4 SPECS/apmud.spec:1.5
--- SPECS/apmud.spec:1.4	Mon Dec 12 14:44:45 2005
+++ SPECS/apmud.spec	Fri Apr 14 19:40:01 2006
@@ -11,6 +11,7 @@
 Source1:	%{name}.init
 Patch0:		%{name}-pwrctl.patch
 URL:		http://linuxppc.jvc.nl/
+BuildRequires:	rpmbuild(macros) >= 1.268
 Requires(post,preun):	/sbin/chkconfig
 Requires:	dev
 Requires:	hdparm
@@ -61,17 +62,11 @@
 
 %post
 /sbin/chkconfig --add pmud
-if [ -f /var/lock/subsys/pmud ]; then
-	/etc/rc.d/init.d/pmud restart >&2
-else
-	echo "Run \"/etc/rc.d/init.d/pmud start\" to start pmud daemon."
-fi
+%service pmud restart "pmud daemon"
 
 %preun
 if [ "$1" = "0" ]; then
-	if [ -f /var/lock/subsys/pmud ]; then
-		/etc/rc.d/init.d/pmud stop >&2
-	fi
+	%service pmud stop
 	/sbin/chkconfig --del pmud
 fi
 
@@ -92,6 +87,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.5  2006/04/14 17:40:01  glen
+- use %service
+
 Revision 1.4  2005/12/12 13:44:45  glen
 - adapterized (sorted %verify attrs)
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/apmud.spec?r1=1.4&r2=1.5&f=u



More information about the pld-cvs-commit mailing list