]> git.pld-linux.org Git - packages/VirtualBox.git/commitdiff
- register/unregister virtualbox service on (un)installation
authorhawk <hawk@pld-linux.org>
Sun, 10 Feb 2008 20:05:58 +0000 (20:05 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    VirtualBox.spec -> 1.58

VirtualBox.spec

index d5ef5762e35efbde30d39f2d180026cf62221971..56f157666cfdb2fffa5f9aaa0a1189a3bafb2ac6 100644 (file)
@@ -70,6 +70,7 @@ BuildRequires:        gcc-multilib
 BuildRequires: libstdc++-multilib-devel
 # TODO: How to add glibc-devel.i686 here ?
 %endif
+Requires(post,preun):  /sbin/chkconfig
 Requires(postun):      /usr/sbin/groupdel
 Requires(pre): /usr/bin/getgid
 Requires(pre): /usr/sbin/groupadd
@@ -360,6 +361,16 @@ rm -rf $RPM_BUILD_ROOT
 %pre
 %groupadd -g 221 -r -f vbox
 
+%post
+/sbin/chkconfig --add virtualbox
+%service virtualbox restart "VirtualBox"
+
+%preun
+if [ "$1" = "0" ]; then
+       %service virtualbox stop
+       /sbin/chkconfig --del virtualbox
+fi
+
 %postun
 if [ "$1" = "0" ]; then
        %groupremove vbox
This page took 0.075772 seconds and 4 git commands to generate.