- use %service
authorElan Ruusamäe <glen@pld-linux.org>
Sun, 16 Apr 2006 21:36:13 +0000 (21:36 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    dspam.spec -> 1.56

dspam.spec

index 61a5d7b..4782234 100644 (file)
@@ -32,6 +32,7 @@ BuildRequires:        libtool
 %{?with_mysql:BuildRequires:   mysql-devel}
 BuildRequires: openldap-devel
 %{?with_pgsql:BuildRequires:   postgresql-devel}
+BuildRequires: rpmbuild(macros) >= 1.268
 BuildRequires: sed >= 4.0
 %{?with_sqlite:BuildRequires:  sqlite3-devel}
 BuildRequires: zlib-devel
@@ -346,17 +347,11 @@ EOF
 
 %post
 /sbin/chkconfig --add dspam
-if [ -f /var/lock/subsys/dspam ]; then
-       /etc/rc.d/init.d/dspam restart 1>&2
-else
-       echo "Run \"/etc/rc.d/init.d/dspam start\" to start dspam daemon."
-fi
+%service dspam restart "dspam daemon"
 
 %preun
 if [ "$1" = "0" ]; then
-       if [ -f /var/lock/subsys/dspam ]; then
-               /etc/rc.d/init.d/dspam stop 1>&2
-       fi
+       %service dspam stop
        /sbin/chkconfig --del dspam
 fi
 
This page took 0.109616 seconds and 4 git commands to generate.