diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2002-09-29 22:52:22 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2002-09-29 22:52:22 +0000 |
commit | a32896598cf32e871afefaa4f3af32c1707402a1 (patch) | |
tree | 1c70961f68c88c2c17e251873c4ca0b21af4a472 /distrib | |
parent | cdc0646c5a183e53cb0f0f1b8ef3466423ca021f (diff) |
Keep track of all devices that makedev() creates and recreate
them in the installed system.
ok deraadt@. (which I forgot to mention for the last commit).
Diffstat (limited to 'distrib')
-rw-r--r-- | distrib/miniroot/install.sub | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/distrib/miniroot/install.sub b/distrib/miniroot/install.sub index a1945d2a8c2..3955e60e0fc 100644 --- a/distrib/miniroot/install.sub +++ b/distrib/miniroot/install.sub @@ -1,4 +1,4 @@ -# $OpenBSD: install.sub,v 1.261 2002/09/29 22:45:44 krw Exp $ +# $OpenBSD: install.sub,v 1.262 2002/09/29 22:52:21 krw Exp $ # $NetBSD: install.sub,v 1.5.2.8 1996/09/02 23:25:02 pk Exp $ # # Copyright (c) 1997-2002 Todd Miller, Theo de Raadt, Ken Westerback @@ -428,6 +428,7 @@ makedev() { if [ ! -c /dev/r${_d}c ]; then if [ -r /dev/MAKEDEV ]; then (cd /dev; sh MAKEDEV $_d) + DEVSMADE=`addel $_d $DEVSMADE` else echo "Device nodes for $_d are missing, and MAKEDEV" echo "does not exist to create them with. Sorry." @@ -1920,12 +1921,19 @@ set_machdep_apertureallowed() { } finish_up() { + local _dev + set_timezone - echo -n "Making all device nodes (by running /dev/MAKEDEV all) ..." + echo -n "Making all device nodes..." cd /mnt/dev sh MAKEDEV all - echo "... done." + # Make sure any devices we added as a result of makedev() calls + # are recreated in installed system. + for _dev in $DEVSMADE; do + sh MAKEDEV $_dev + done + echo "done." cd / md_installboot $ROOTDISK @@ -1974,6 +1982,9 @@ DKDEVS=`get_dkdevs` CDDEVS=`get_cddevs` IFDEVS=`get_ifdevs` +# Devices created with makedev(). +DEVSMADE= + # extra "site" set can be provided by person doing install or upgrade. THESETS="base etc misc comp man game xbase xshare xfont xserv site $MDSETS" |