3 # look for esp and format it when not already done
4 esp=`{ls /dev/$disk/esp >[2]/dev/null}
5 if(~ $#esp 1 && ! ~ `{fstype $esp} dos){
7 echo 'Here appears to be a unformated EFI system partition:'
10 prompt 'Initialize FAT on EFI system partition' yes no
13 # 4k clusters to force FAT32
14 disk/format -d -c 8 -l ESP $esp
18 # look for plan9 partition in the DOS partition table (if any)
19 p9part=`{disk/fdisk /dev/$disk/data >[2]/dev/null </dev/null | grep PLAN9 | sed 1q | sed 's/ *(p.) .*/\1/'}
26 echo 'If you use the Windows NT/2000/XP master boot record'
27 echo 'or a master boot record from a Unix clone (e.g., LILO or'
28 echo 'FreeBSD bootmgr), it is probably safe to continue using'
29 echo 'that boot record rather than install the Plan 9 boot record.'
31 prompt 'Install the Plan 9 master boot record' yes no
34 disk/mbr -m /386/mbr /dev/$disk/data
37 prompt 'Mark the Plan 9 partition active' yes no
40 { echo 'A '^$p9part; echo w } | disk/fdisk /dev/$disk/data >[2]/dev/null >/dev/null
44 echo 'The Plan 9 partition is now marked as active.'