aboutsummaryrefslogtreecommitdiff
path: root/release/scripts/mk-vmimage.sh
diff options
context:
space:
mode:
authorGlen Barber <gjb@FreeBSD.org>2015-04-23 01:04:14 +0000
committerGlen Barber <gjb@FreeBSD.org>2015-04-23 01:04:14 +0000
commit08a75d1f0e7d885f5a891e0e3e64a540daf15689 (patch)
tree9607905389472283ff3a3364d44593b216534d8b /release/scripts/mk-vmimage.sh
parente54379826ce0a52cd54f3946cd882d1e22fcf114 (diff)
downloadsrc-08a75d1f0e7d885f5a891e0e3e64a540daf15689.tar.gz
src-08a75d1f0e7d885f5a891e0e3e64a540daf15689.zip
Create the arm64/aarch64 VM disk image as MBR instead of
GPT scheme. UEFI needs to know the unique partition GUID with GPT, which changes each time. Specifically, the QEMU EFI BIOS file has this hard-coded.[1] Since the GPT labels are now unavailable, unconditionally label the root filesystem as 'rootfs' with newfs(8), since it does not hurt anything anywhere else. For the arm64 case, '/' is mounted from /dev/ufs/rootfs; for all other VM images, '/' is mounted from /dev/gpt/rootfs. Unfortunately, since the /dev/gpt/swapfs label is also lost, set NOSWAP=1 for the arm64/aarch64 images. This is temporary, until I figure out a scalable solution to this. But, a certain piece of softare was written "very fast", and ended up living for 15 years. We can deal with this for a week or so. Information from: andrew, emaste [1] Sponsored by: The FreeBSD Foundation
Notes
Notes: svn path=/head/; revision=281876
Diffstat (limited to 'release/scripts/mk-vmimage.sh')
-rwxr-xr-xrelease/scripts/mk-vmimage.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/release/scripts/mk-vmimage.sh b/release/scripts/mk-vmimage.sh
index d5985ceb0d25..fd84216a99fe 100755
--- a/release/scripts/mk-vmimage.sh
+++ b/release/scripts/mk-vmimage.sh
@@ -93,6 +93,16 @@ main() {
. "${VMCONFIG}"
fi
+ case ${TARGET}:${TARGET_ARCH} in
+ arm64:aarch64)
+ ROOTLABEL="ufs"
+ NOSWAP=1
+ ;;
+ *)
+ ROOTLABEL="gpt"
+ ;;
+ esac
+
vm_create_base
vm_install_base
vm_extra_install_base