merge changes from HEAD
[myplc.git] / myplc.spec
index 70e656f..0a6a188 100644 (file)
@@ -1,13 +1,13 @@
 Vendor: PlanetLab
 Packager: PlanetLab Central <support@planet-lab.org>
-Distribution: PlanetLab 3.3
+Distribution: PlanetLab 4.0
 URL: http://cvs.planet-lab.org/cvs/myplc
 
 Summary: PlanetLab Central (PLC) Portable Installation
 Name: myplc
-Version: 0.4
+Version: 0.5
 Release: 1%{?pldistro:.%{pldistro}}%{?date:.%{date}}
-License: BSD
+License: PlanetLab
 Group: Applications/Systems
 Source0: %{name}-%{version}.tar.gz
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
@@ -73,15 +73,19 @@ if [ -x %{_sysconfdir}/init.d/plc ] ; then
 fi
 
 %post
-chkconfig --add plc
-chkconfig plc on
+if [ -x /sbin/chkconfig ] ; then
+    /sbin/chkconfig --add plc
+    /sbin/chkconfig plc on
+fi
 
 %preun
 # 0 = erase, 1 = upgrade
 if [ $1 -eq 0 ] ; then
-    service plc stop
-    chkconfig plc off
-    chkconfig --del plc
+    %{_sysconfdir}/init.d/plc stop
+    if [ -x /sbin/chkconfig ] ; then
+        /sbin/chkconfig plc off
+       /sbin/chkconfig --del plc
+    fi
 fi
 
 %files