Subject: ramdisk setup changes:
To: None <tech-install@netbsd.org>
From: Jonathan Stone <jonathan@DSG.Stanford.EDU>
List: tech-install
Date: 11/20/1998 20:53:21
After some help from CGD with elf symbol-hiding in the crunch tools,
and some VM-bug identification, I got the ramdisk-in-miniroot tools
working on the pmax.  Once those bugs were fixed, it was really very
simple to use.  I've said this before, but a big `thank you' to
everyone who put the tools for miniroot-construction together.


with some cleanup, the tools in src/distrib/<arch> could be even
better still.  A lot of Makefile rules have been cut-and-pasted into
each port; so have several infrastructure scripts.
Surely those could (and should) be folded into one MI copy?

some of the files put into RAMdisk images exist purely for the benefit
of sysinst. Some, like preinstall.disktab, really should be MI.  I
think we should move them into a sub-directory of sysinst, and reach
over into sysinst to grab then when building RAmdisks: they're part of
sysinst, after all.

So i propose we:

    a. create a new directory, src/distrib/ramdisk/, containing
        both the `mi' tools needed to build a ramdisk and any MI
	contents. that's the   scripts
	     list2sh.awk
	     runlist.sh
	which we currently duplicate in each port, plus new files
	    mtree.conf
	    crunch.conf
	    list
	containing the factored-out `mi' portions of all ports' mtree.conf, 
	ramdisk.conf crunchgen files,  and `list' files, respectively.

     b. extend crunchconfig(8) and the list scripts to run over multiple
        input files, (mtree -e should suffices for mtree),
	 and then update all ports to use the `mi' files and scripts.

     c. create a new directory, src/distrib/utils/sysinst/ramdisk,
        containing file like preinstal.disktab, which are templates for
	sysinst.

     d. move any references to sysinst-specific  files into  new files,
            src/distrib/utils/sysinst/ramdisk/sysinst-tools.conf
            src/distrib/utils/sysinst/ramdisk/list
        and  feed those to crunchconf and the list scripts on all
	ports which use sysinst, rather than duplicating the files
	used by sysinst on each port.
     e. Create similar setups for any MI components used by the old-style
        install.sh and upgrade.sh scripts.

I havent yet done any of this; I've looked over the alpha and i386 and
sparc set-ups whilst learning how to build a pmax ramdisk. It all
looks eminently do-able, and it would have some advantages: the setup
for sysinst woudl be more consistent, we can write more MI
documentation for it, you need only change one place to add a new
sysinst template file (dif/when we add more system-configuration menus
to sysinst).  It should make maintaining separate ramdisks for both
sysinst and the old scripts, side-by-side, easier too.

So thats the idea.  Comments?  Anyone object if I take a stab
at implementing it?