diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2020-06-27 15:35:30 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2020-06-27 15:35:30 +0000 |
commit | 2a4e82f6774eaf7ee452093cb4d4a049687e95d8 (patch) | |
tree | 54e5ad586592efca7dfa7132967a5f21a9cba5af /distrib/loongson/ramdisk | |
parent | 88aa1dbacd2d4a01b00a325be1b0bf2862d7ecad (diff) |
convert macppc, octeon, and loongson to use MI installboot, removing
special case scripting in install.md.
(macppc still requires manual steps for HFS bootmode)
tested by krw, visa, gkoehler
Diffstat (limited to 'distrib/loongson/ramdisk')
-rw-r--r-- | distrib/loongson/ramdisk/install.md | 20 | ||||
-rw-r--r-- | distrib/loongson/ramdisk/list | 3 |
2 files changed, 7 insertions, 16 deletions
diff --git a/distrib/loongson/ramdisk/install.md b/distrib/loongson/ramdisk/install.md index ab8f254e106..48185267d35 100644 --- a/distrib/loongson/ramdisk/install.md +++ b/distrib/loongson/ramdisk/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.27 2017/01/22 23:43:54 rpe Exp $ +# $OpenBSD: install.md,v 1.28 2020/06/27 15:35:27 deraadt Exp $ # # Copyright (c) 1996 The NetBSD Foundation, Inc. # All rights reserved. @@ -32,21 +32,11 @@ # md_installboot() { - local _disk=$1 - - # Use cat below to avoid holes created by cp(1) - if mount -t ext2fs /dev/${_disk}i /mnt2 && - mkdir -p /mnt2/boot && - cat /mnt/usr/mdec/boot > /mnt2/boot/boot && - { [[ $(sysctl -n hw.product) != Gdium ]] || - cp /mnt/bsd /mnt2/boot/bsd; }; then - umount /mnt2 - return + if ! installboot -r /mnt ${1}; then + echo "\nFailed to install bootblocks." + echo "You will not be able to boot OpenBSD from ${1}." + exit fi - - echo "Failed to install bootblocks." - echo "You will not be able to boot OpenBSD from $_disk." - exit } md_prep_fdisk() { diff --git a/distrib/loongson/ramdisk/list b/distrib/loongson/ramdisk/list index 744ec387529..a3922bbc08b 100644 --- a/distrib/loongson/ramdisk/list +++ b/distrib/loongson/ramdisk/list @@ -1,4 +1,4 @@ -# $OpenBSD: list,v 1.34 2019/06/07 14:39:57 deraadt Exp $ +# $OpenBSD: list,v 1.35 2020/06/27 15:35:27 deraadt Exp $ SRCDIRS distrib/special @@ -62,6 +62,7 @@ LINK instbin usr/bin/sed LINK instbin usr/bin/signify LINK instbin usr/bin/tee LINK instbin usr/sbin/chroot +LINK instbin usr/sbin/installboot LINK instbin usr/sbin/pwd_mkdb ARGVLINK ksh -sh SPECIAL rm bin/md5 |