From 5f91d3f484db5354eba22dd94162e45a708e369a Mon Sep 17 00:00:00 2001 From: cinap_lenrek Date: Fri, 31 Oct 2014 03:15:15 +0100 Subject: [PATCH] efi: add test targets for iso and fat (for documentation only) --- sys/src/boot/efi/mkfile | 27 ++++++++++++++++++++++++--- 1 file changed, 24 insertions(+), 3 deletions(-) diff --git a/sys/src/boot/efi/mkfile b/sys/src/boot/efi/mkfile index c68fa0fb4..c655dc430 100644 --- a/sys/src/boot/efi/mkfile +++ b/sys/src/boot/efi/mkfile @@ -10,9 +10,6 @@ install:V: $TARG cp bootia32.efi /386 cp bootx64.efi /386 -clean:V: - rm -f *.[68] *.out $TARG - bootia32.efi: pe32.8 efi.8 fs.8 pxe.8 sub.8 8l -l -H3 -T$IMAGEBASE -o $target $prereq @@ -54,3 +51,27 @@ sub.6: sub.c 6c $CFLAGS sub.c %.6: $HFILES + + +test.fat:D: bootia32.efi bootx64.efi + s = $target.$pid + rm -f /srv/$s $target + dd -if /dev/zero -of $target -bs 65536 -count 256 + disk/format -xd -t hard $target + dossrv -f $target $s + mount -c /srv/$s /n/esp + mkdir /n/esp/efi + mkdir /n/esp/efi/boot + cp bootia32.efi /n/esp/efi/boot + cp bootx64.efi /n/esp/efi/boot + cp /386/9pcf /n/esp + echo 'bootfile=9pcf' >/n/esp/plan9.ini + unmount /n/esp + rm /srv/$s + +test.iso:D: test.fat + disk/mk9660 -E test.fat -p <{echo test.fat} -s . $target + + +clean:V: + rm -f *.[68] *.out $TARG test.*