From 4c4e2b3de336ac6e062eec7ec357b60d9da126ab Mon Sep 17 00:00:00 2001 From: Warner Losh Date: Mon, 28 Sep 2020 06:00:56 +0000 Subject: [PATCH] Speciy the dev in an easily changed variable Rather than hard coding ada0 everywhere, use ${dev}. Also, set dev=vtbd0 since both qemu and bhyve support this. More work should be done to use labels instead for fstab. qemu scripts likely need adjustment. And we should also likely generate byhve scripts too. --- tools/boot/rootgen.sh | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/tools/boot/rootgen.sh b/tools/boot/rootgen.sh index eb340d96ce83..b61fff647b5c 100755 --- a/tools/boot/rootgen.sh +++ b/tools/boot/rootgen.sh @@ -7,6 +7,7 @@ iterations=50000 # The smallest FAT32 filesystem is 33292 KB espsize=33292 +dev=vtbd0 # # Builds all the bat-shit crazy combinations we support booting from, @@ -20,7 +21,7 @@ espsize=33292 # This assumes an external program install-boot.sh which will install # the appropriate boot files in the appropriate locations. # -# These images assume ada0 will be the root image. We should likely +# These images assume ${dev} will be the root image. We should likely # use labels, but we don't. # # Assumes you've already rebuilt... maybe bad? Also maybe bad: the env @@ -42,7 +43,7 @@ mk_nogeli_gpt_ufs_legacy() { img=$2 cat > ${src}/etc/fstab < ${src}/etc/fstab < ${src}/etc/fstab < ${src}/etc/fstab < ${src}/etc/fstab < ${src}/etc/fstab < ${mntpt}/etc/fstab < ${mntpt}/etc/fstab < ${mntpt}/etc/fstab < ${src}/etc/fstab < ${DESTDIR}/boot.config cat > ${DESTDIR}/boot/loader.conf <