diff options
author | root <root@rshg054.dnsready.net> | 2012-07-07 00:02:03 +0000 |
---|---|---|
committer | root <root@rshg054.dnsready.net> | 2012-07-07 00:02:03 +0000 |
commit | b7c6c9c7844914d1d0617a24b9e3a84d691d1f64 (patch) | |
tree | e83e42e7aa3b5f01bbd1a22f539aa807e586e04b /libre/virtualbox-libre/vboxbuild | |
parent | ce1cc063cc56f59a630e758c92a9f8ac67a24c32 (diff) |
Sat Jul 7 00:02:03 UTC 2012
Diffstat (limited to 'libre/virtualbox-libre/vboxbuild')
-rw-r--r-- | libre/virtualbox-libre/vboxbuild | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/libre/virtualbox-libre/vboxbuild b/libre/virtualbox-libre/vboxbuild index 4bc8e0c9d..350d0c6ad 100644 --- a/libre/virtualbox-libre/vboxbuild +++ b/libre/virtualbox-libre/vboxbuild @@ -1,13 +1,23 @@ #!/bin/bash -. /etc/rc.conf -. /etc/rc.d/functions . /etc/vbox/vbox.cfg MODLIST=() LOG="/var/log/vbox-install.log" >| "$LOG" +stat_busy() { + printf '==> %s ... ' "$1" +} + +stat_done() { + echo 'done' +} + +stat_fail() { + echo 'failed' +} + if [[ $INSTALL_DIR ]]; then VBOXMANAGE=$INSTALL_DIR/VBoxManage BUILDVBOXDRV=$INSTALL_DIR/src/vboxdrv/build_in_tmp @@ -29,7 +39,7 @@ if (( ${#MODLIST[*]} )); then modprobe -ar "${MODLIST[@]}" && stat_done || stat_fail fi -for kdir in /lib/modules/[2-3]*; do +for kdir in /usr/lib/modules/[2-3]*; do if [[ ! -d $kdir/kernel ]]; then # found a stale kernel mods=("$kdir/extramodules"{drv,netadp,netflt,pci}.ko*) @@ -51,8 +61,8 @@ if (( ! $# )); then fi for kernver; do - export KERN_DIR=/lib/modules/$kernver/build - export MODULE_DIR=/lib/modules/$kernver/extramodules + export KERN_DIR=/usr/lib/modules/$kernver/build + export MODULE_DIR=/usr/lib/modules/$kernver/extramodules if [[ ! -d $KERN_DIR ]]; then printf "error: \`%s' does not appear to be a valid kernel build directory.\n" \ "$KERN_DIR" |