summaryrefslogtreecommitdiff
path: root/functions
diff options
context:
space:
mode:
authorDaniel Baumann <daniel@debian.org>2011-04-05 14:08:30 +0200
committerDaniel Baumann <daniel@debian.org>2011-04-05 15:51:09 +0200
commit3de9626c2723b40527f78ca08fa285ed2bab890b (patch)
treef7c6f3e770ee7600d3fea6c0aa0ce36b46eeb995 /functions
parent87f788b31df0b6f143c8ac729a3518d1b7f5d19c (diff)
downloadvyos-live-build-tmp-vbox.tar.gz
vyos-live-build-tmp-vbox.zip
Adding support for virtualbox binary images (incomplete).tmp-vbox
Diffstat (limited to 'functions')
-rwxr-xr-xfunctions/defaults.sh46
1 files changed, 43 insertions, 3 deletions
diff --git a/functions/defaults.sh b/functions/defaults.sh
index 4a49b4838..ee150a371 100755
--- a/functions/defaults.sh
+++ b/functions/defaults.sh
@@ -556,9 +556,6 @@ Set_defaults ()
# Setting chroot filesystem
LB_CHROOT_FILESYSTEM="${LB_CHROOT_FILESYSTEM:-squashfs}"
- # Setting virtual root size
- LB_VIRTUAL_ROOT_SIZE="${LB_VIRTUAL_ROOT_SIZE:-10000}"
-
# Setting whether to expose root filesystem as read only
LB_EXPOSED_ROOT="${LB_EXPOSED_ROOT:-false}"
@@ -1013,6 +1010,49 @@ Set_defaults ()
;;
esac
+ LB_VIRTUALBOX_NAME="${LB_VIRTUALBOX_NAME:-${LB_ISO_APPLICATION}}"
+
+ case "${LB_MODE}" in
+ debian|emdebian|progress)
+ case "${LB_ARCHITECTURE}" in
+ amd64)
+ LB_VIRTUALBOX_OSTYPE="${LB_VIRTUALBOX_OSTYPE:-Debian_64}"
+ ;;
+
+ *)
+ LB_VIRTUALBOX_OSTYPE="${LB_VIRTUALBOX_OSTYPE:-Debian}"
+ ;;
+ esac
+ ;;
+
+ ubuntu)
+ case "${LB_ARCHITECTURE}" in
+ amd64)
+ LB_VIRTUALBOX_OSTYPE="${LB_VIRTUALBOX_OSTYPE:-Ubuntu_64}"
+ ;;
+
+ *)
+ LB_VIRTUALBOX_OSTYPE="${LB_VIRTUALBOX_OSTYPE:-Ubuntu}"
+ ;;
+ esac
+ ;;
+
+ *)
+ case "${LB_ARCHITECTURE}" in
+ amd64)
+ LB_VIRTUALBOX_OSTYPE="${LB_VIRTUALBOX_OSTYPE:-Linux26_64}"
+ ;;
+
+ *)
+ LB_VIRTUALBOX_OSTYPE="${LB_VIRTUALBOX_OSTYPE:-Linux26}"
+ ;;
+ esac
+ ;;
+ esac
+
+ # Setting virtual root size
+ LB_VIRTUAL_ROOT_SIZE="${LB_VIRTUAL_ROOT_SIZE:-10000}"
+
# Setting memtest option
LB_MEMTEST="${LB_MEMTEST:-memtest86+}"