summaryrefslogtreecommitdiffstats
path: root/systemtap.spec
diff options
context:
space:
mode:
authorDave Brolley <brolley@redhat.com>2009-10-29 16:24:33 -0400
committerDave Brolley <brolley@redhat.com>2009-10-29 16:24:33 -0400
commitd210cb1c6405a7560c98961af286a6aee36df7ef (patch)
treebb05535e6998db2b76bffbce0032fae52a1e2955 /systemtap.spec
parent43656389e923de1a7ccbb9fd0d8bc9a1f8f3b968 (diff)
downloadsystemtap-steved-d210cb1c6405a7560c98961af286a6aee36df7ef.tar.gz
systemtap-steved-d210cb1c6405a7560c98961af286a6aee36df7ef.tar.xz
systemtap-steved-d210cb1c6405a7560c98961af286a6aee36df7ef.zip
Rework for bugs found during testing.
Diffstat (limited to 'systemtap.spec')
-rw-r--r--systemtap.spec8
1 files changed, 8 insertions, 0 deletions
diff --git a/systemtap.spec b/systemtap.spec
index e08a95c0..76a91a45 100644
--- a/systemtap.spec
+++ b/systemtap.spec
@@ -314,6 +314,8 @@ chgrp stap-server %{_localstatedir}/log/stap-server.log
exit 0
%preun server
+# Check that this is the actual deinstallation of the package, as opposed to
+# just removing the old package on upgrade.
if [ $1 = 0 ] ; then
/sbin/service stap-server stop >/dev/null 2>&1
/sbin/chkconfig --del stap-server
@@ -321,6 +323,8 @@ fi
exit 0
%postun server
+# Check whether this is an upgrade of the package.
+# If so, restart the service if it's running
if [ "$1" -ge "1" ] ; then
/sbin/service stap-server condrestart >/dev/null 2>&1 || :
fi
@@ -331,6 +335,8 @@ exit 0
exit 0
%preun initscript
+# Check that this is the actual deinstallation of the package, as opposed to
+# just removing the old package on upgrade.
if [ $1 = 0 ] ; then
/sbin/service systemtap stop >/dev/null 2>&1
/sbin/chkconfig --del systemtap
@@ -338,6 +344,8 @@ fi
exit 0
%postun initscript
+# Check whether this is an upgrade of the package.
+# If so, restart the service if it's running
if [ "$1" -ge "1" ] ; then
/sbin/service systemtap condrestart >/dev/null 2>&1 || :
fi