wok diff virtualbox-ose-guestutils/receipt @ rev 23352
updated perl-io-socket-ssl (2.060 -> 2.068)
author | Hans-G?nter Theisgen |
---|---|
date | Tue Mar 31 09:52:25 2020 +0100 (2020-03-31) |
parents | 38ec9a00ec36 |
children |
line diff
1.1 --- a/virtualbox-ose-guestutils/receipt Sat Jul 05 12:28:30 2014 +0000 1.2 +++ b/virtualbox-ose-guestutils/receipt Tue Mar 31 09:52:25 2020 +0100 1.3 @@ -65,39 +65,39 @@ 1.4 1.5 pre_remove() 1.6 { 1.7 - if chroot $1/ lspci | grep -qi virtualbox; then 1.8 - sed -i "s/vboxguest vboxsf vboxvideo //" $1/etc/rcS.conf 1.9 - sed -i '/# VBoxService daemon options./{N;N;N;d}' $1/etc/daemons.conf 1.10 - sed -i 's/VBoxService //' $1/etc/rcS.conf 1.11 - chroot $1/ delgroup vboxsf 1.12 - sed -i 's/^\tDriver.*$/\tDriver "vesa"/' $1/etc/X11/xorg.conf.d/60-Device.conf 1.13 + if chroot "$1/" lspci | grep -qi virtualbox; then 1.14 + sed -i "s/vboxguest vboxsf vboxvideo //" "$1/etc/rcS.conf" 1.15 + sed -i '/# VBoxService daemon options./{N;N;N;d}' "$1/etc/daemons.conf" 1.16 + sed -i 's/VBoxService //' "$1/etc/rcS.conf" 1.17 + chroot "$1/" delgroup vboxsf 1.18 + sed -i 's/^\tDriver.*$/\tDriver "vesa"/' "$1/etc/X11/xorg.conf.d/60-Device.conf" 1.19 fi 1.20 } 1.21 1.22 post_install() 1.23 { 1.24 - if chroot $1/ lspci | grep -qi virtualbox; then 1.25 - #chroot $1/ udevadm control --reload 1.26 - grep -qs VBOXSERVICE_OPTIONS $1/etc/daemons.conf || 1.27 - cat >> $1/etc/daemons.conf << "EOT" 1.28 + if chroot "$1/" lspci | grep -qi virtualbox; then 1.29 + #chroot "$1/" udevadm control --reload 1.30 + grep -qs VBOXSERVICE_OPTIONS "$1/etc/daemons.conf" || 1.31 + cat >> "$1/etc/daemons.conf" << "EOT" 1.32 # VBoxService daemon options. 1.33 VBOXSERVICE_OPTIONS="" 1.34 1.35 EOT 1.36 - KERNEL_VERSION=$( chroot $1/ uname -r) 1.37 - chroot $1/ depmod -a $KERNEL_VERSION 1.38 - #chroot $1/ modprobe -a vboxguest vboxsf vboxvideo 1.39 - sed -i 's/^\tDriver.*$/\tDriver "vboxvideo"/' $1/etc/X11/xorg.conf.d/60-Device.conf 1.40 - grep -qs vboxguest $1/etc/rcS.conf || 1.41 - sed -i 's/LOAD_MODULES="/&vboxguest vboxsf vboxvideo /' $1/etc/rcS.conf 1.42 - grep -qs VBoxService $1/etc/rcS.conf || 1.43 - sed -i 's/RUN_DAEMONS="/&VBoxService /' $1/etc/rcS.conf 1.44 - grep -qs vboxsf $1/etc/group || chroot $1/ addgroup -g 109 vboxsf 1.45 + KERNEL_VERSION=$( chroot "$1/" uname -r) 1.46 + chroot "$1/" depmod -a $KERNEL_VERSION 1.47 + #chroot "$1/" modprobe -a vboxguest vboxsf vboxvideo 1.48 + sed -i 's/^\tDriver.*$/\tDriver "vboxvideo"/' "$1/etc/X11/xorg.conf.d/60-Device.conf" 1.49 + grep -qs vboxguest "$1/etc/rcS.conf" || 1.50 + sed -i 's/LOAD_MODULES="/&vboxguest vboxsf vboxvideo /' "$1/etc/rcS.conf" 1.51 + grep -qs VBoxService "$1/etc/rcS.conf" || 1.52 + sed -i 's/RUN_DAEMONS="/&VBoxService /' "$1/etc/rcS.conf" 1.53 + grep -qs vboxsf "$1/etc/group" || chroot "$1/" addgroup -g 109 vboxsf 1.54 echo "add yourself to vboxsf group if you want to access" 1.55 echo "host shared folder: addgroup $USER vboxsf" 1.56 #i can't get udev to do its work 1.57 #echo "then logout and login again" 1.58 - #chroot $1/ /etc/init.d/VBoxService start &> /dev/null 1.59 + #chroot "$1/" /etc/init.d/VBoxService start &> /dev/null 1.60 echo "then reboot" 1.61 else 1.62 echo "this is not a virtual machine,"