Hi again, I figured out a neater way of doing this; please see new patch. I've dry-run it via the GRUB command line and it seems to work just right.
Thanks, Regards, -- Steven Chamberlain ste...@pyro.eu.org
--- grub-kfreebsd-cdrom.cfg.orig 2011-12-10 20:45:22.000000000 +0000 +++ grub-kfreebsd-cdrom.cfg 2011-12-10 21:06:23.000000000 +0000 @@ -31,13 +31,15 @@ menuentry "" { } function menuentry_set { - menuentry "Default install$desc_suffix" { + menuentry "Default install$desc_suffix" "$mfsroot_path" { + set mfsroot_path="$2" echo "Loading ..." kfreebsd $kernel_path kfreebsd_module $mfsroot_path type=mfs_root } - menuentry "Automated install$desc_suffix" { + menuentry "Automated install$desc_suffix" "$mfsroot_path" { + set mfsroot_path="$2" echo "Loading ..." kfreebsd $kernel_path kfreebsd_module $mfsroot_path type=mfs_root @@ -45,7 +47,8 @@ function menuentry_set { set kFreeBSD.priority=critical } - menuentry "Expert install$desc_suffix" { + menuentry "Expert install$desc_suffix" "$mfsroot_path" { + set mfsroot_path="$2" echo "Loading ..." kfreebsd $kernel_path kfreebsd_module $mfsroot_path type=mfs_root @@ -53,6 +56,8 @@ function menuentry_set { } } +insmod test + # Default kernel (8.x) if test -e /boot/kernel/kfreebsd.gz ; then set kernel_path="/boot/kernel/kfreebsd.gz"