]> git.pld-linux.org Git - packages/VirtualBox.git/blame - VirtualBox.sh
- BR fltk-devel
[packages/VirtualBox.git] / VirtualBox.sh
CommitLineData
b3e14e5c 1#!/bin/sh
b3e14e5c 2BINFILE=$(basename "$0")
a62e015f 3VBOXDIR=@LIBDIR@/VirtualBox
b3e14e5c 4
5show_message() {
6 if [ ! -z "$DISPLAY" ] && [ -x /usr/bin/gxmessage ]; then
661c142c 7 echo -e "$1" | gxmessage --center --buttons GTK_STOCK_OK -wrap -geometry 400x150 -name $BINFILE -file -
b3e14e5c 8 else
a3c2b34e 9 echo -e "$1"
b3e14e5c 10 fi
11}
12
13if [ ! -d "$VBOXDIR" ]; then
a62e015f 14 show_message "Can't find VirtualBox libraries! Can't continue!.\nCorrect this situation or contact with your system administrator."
b3e14e5c 15 exit 1
16fi
17
18if [ ! -c /dev/vboxdrv ]; then
a62e015f 19 show_message "Special character device /dev/vboxdrv doesn't exists!\nCheck your installation and whether vboxdrv kernel module is loaded."
b3e14e5c 20 exit 1
21fi
22
23if [ ! -w /dev/vboxdrv ]; then
24 show_message "You don't have write access to /dev/vboxdrv!\nCorrect this situation or contact with your system administrator."
25 exit 1
26fi
27
a3c2b34e
ER
28export LD_LIBRARY_PATH=$VBOXDIR
29exec $VBOXDIR/$BINFILE ${1:+"$@"}
This page took 0.060187 seconds and 4 git commands to generate.