]> git.pld-linux.org Git - packages/autofs.git/commitdiff
- use %service
authorElan Ruusamäe <glen@pld-linux.org>
Fri, 24 Feb 2006 15:20:04 +0000 (15:20 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    autofs.spec -> 1.68

autofs.spec

index 30043a4402103d89c1c63cd76ef7c67ec7b31eac..4b9e8ba80bb36bc2a612b4866b0ab12c3e17c8a2 100644 (file)
@@ -28,16 +28,17 @@ Source6:    %{name}.sysconfig
 Patch0:                %{name}-open_max.patch
 Patch1:                %{name}-hesiod-includes.patch
 Patch2:                http://www.kernel.org/pub/linux/daemons/autofs/v4/%{name}-4.1.4-misc-fixes.patch
-Patch3:                http://www.kernel.org/pub/linux/daemons/autofs/v4/%{name}-4.1.4-multi-parse-fix.patch   
+Patch3:                http://www.kernel.org/pub/linux/daemons/autofs/v4/%{name}-4.1.4-multi-parse-fix.patch
 Patch4:                http://www.kernel.org/pub/linux/daemons/autofs/v4/%{name}-4.1.4-no-unlink-upstream.patch
-Patch5:                http://www.kernel.org/pub/linux/daemons/autofs/v4/%{name}-4.1.4-non-replicated-ping.patch 
-BuildRequires: automake
+Patch5:                http://www.kernel.org/pub/linux/daemons/autofs/v4/%{name}-4.1.4-non-replicated-ping.patch
 BuildRequires: autoconf
+BuildRequires: automake
 BuildRequires: bind-devel
 BuildRequires: openldap-devel >= 2.3.0
-PreReq:                rc-scripts
+BuildRequires: rpmbuild(macros) >= 1.268
 Requires(post,preun):  /sbin/chkconfig
 Requires:      mktemp
+Requires:      rc-scripts
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %define                _sysconfdir     /etc/autofs
@@ -136,22 +137,16 @@ rm -rf $RPM_BUILD_ROOT
 
 %post
 /sbin/chkconfig --add autofs
-# triggerpostun would get called after %post
+# triggerpostun would get called after %%post
 if [ -f /var/lock/subsys/automount ]; then
-       mv /var/lock/subsys/automount /var/lock/subsys/autofs
-fi
-if test -r /var/lock/subsys/autofs; then
-       /etc/rc.d/init.d/autofs restart 1>&2
-else
-       echo "Run \"/etc/rc.d/init.d/autofs start\" to start autofs daemon."
+       mv /var/lock/subsys/{automount,autofs}
 fi
+%service autofs restart "autofs daemon"
 
 %preun
 if [ "$1" = "0" ]; then
+       %service autofs stop
        /sbin/chkconfig --del autofs
-       if [ -f /var/lock/subsys/autofs ]; then
-               /etc/rc.d/init.d/autofs stop 1>&2
-       fi
 fi
 
 %files
This page took 0.042637 seconds and 4 git commands to generate.