OpenPKG CVS Repository
http://cvs.openpkg.org/
____________________________________________________________________________
Server: cvs.openpkg.org Name: Ralf S. Engelschall
Root: /e/openpkg/cvs Email: [EMAIL PROTECTED]
Module: openpkg-src Date: 16-Dec-2004 13:20:27
Branch: HEAD Handle: 2004121612202600
Modified files:
openpkg-src/softflowd softflowd.spec
Log:
add usual install/upgrade/erase scriptlets
Summary:
Revision Changes Path
1.2 +15 -1 openpkg-src/softflowd/softflowd.spec
____________________________________________________________________________
patch -p0 <<'@@ .'
Index: openpkg-src/softflowd/softflowd.spec
============================================================================
$ cvs diff -u -r1.1 -r1.2 softflowd.spec
--- openpkg-src/softflowd/softflowd.spec 15 Dec 2004 16:23:23 -0000
1.1
+++ openpkg-src/softflowd/softflowd.spec 16 Dec 2004 12:20:26 -0000
1.2
@@ -34,7 +34,7 @@
Group: Network
License: BSD
Version: 0.9.6
-Release: 20041215
+Release: 20041216
# package options
%option with_fsl yes
@@ -127,3 +127,17 @@
%clean
rm -rf $RPM_BUILD_ROOT
+%post
+ # after upgrade, restart service
+ [ $1 -eq 2 ] || exit 0
+ eval `%{l_rc} softflowd status 2>/dev/null`
+ [ ".$softflowd_active" = .yes ] && %{l_rc} softflowd restart
+ exit 0
+
+%preun
+ # before erase, stop service and remove log files
+ [ $1 -eq 0 ] || exit 0
+ %{l_rc} softflowd stop 2>/dev/null
+ rm -f $RPM_INSTALL_PREFIX/var/softflowd/* >/dev/null 2>&1 || true
+ exit 0
+
@@ .
______________________________________________________________________
The OpenPKG Project www.openpkg.org
CVS Repository Commit List [EMAIL PROTECTED]