3 # desc: create a boot floppy or configure hard disk to boot plan 9
9 echo 'Initializing Plan 9 FAT configuration partition (9fat)'
14 disk=`{echo $fat | sed 's:/dev/::;s:/9fat::'}
16 echo 'You have no 9fat partition. Can''t setup booting.'
20 if(! test -f /tmp/plan9.ini) {
23 echo 'bootargs=local!'^$fs
24 echo 'mouseport='^$mouseport
25 echo 'monitor='^$monitor
26 echo 'vgasize='^$vgasize
27 if(test -f '#ec/*nomp')
33 if(! ~ `{fstype $fat} dos)
35 if(! test -f /srv/dos)
37 if(! mount -c /srv/dos /n/9fat $fat >[2]/dev/null)
39 if not if(! test -f /n/9fat/plan9.ini)
42 if(~ $need9fatformat yes){
43 log Initializing Plan 9 FAT partition.
44 disk/format -r 2 -d -b /386/pbs $fat /n/newfs/386/9bootfat
45 mount -c /srv/dos /n/9fat $fat
47 logprog cp /tmp/plan9.ini /n/9fat/plan9.ini
48 logprog cp /n/newfs/386/9bootfat /n/9fat/9bootfat
49 logprog cp /n/newfs/386/9pcf /n/9fat/9pcf
52 echo 'There are myriad ways to boot a Plan 9 system.'
53 echo 'You can use any of the following.'
55 echo ' plan9 - make the plan 9 disk partition the default for booting'
56 echo ' winnt - add a plan 9 option to windows nt/2000/xp boot manager'
58 echo 'If you are upgrading an extant third edition installation and booting'
59 echo 'from something other than a floppy, you needn''t run anything here.'
60 echo 'Just type ctl-d.'
62 oldbootsetup=$didbootsetup
65 prompt 'Enable boot method' plan9 winnt
68 didbootsetup=$oldbootsetup
73 xxxfat=(/dev/sd*/9fat)
75 if(! ~ `{fstype $xxxfat} dos || ! ~ $didbootsetup 1){