Created
September 25, 2017 02:08
-
-
Save doug65536/73d393357c5115c49573a62aee34b816 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fatdisk.img: mbr-bin bootfat-bin diskfat.mk | |
set -x && \ | |
rm -f fatpart.img fatdisk.img && \ | |
truncate --size=15360K fatpart.img && \ | |
mkfs.vfat -R 16 fatpart.img && \ | |
dd if=bootfat-bin of=fatpart.img \ | |
bs=1 seek=90 skip=90 conv=notrunc && \ | |
truncate --size=16M fatdisk.img && \ | |
echo -e 'o\nn\np\n1\n2048\n\nt\nc\np\nw\n' | \ | |
fdisk fatdisk.img && \ | |
dd if=fatpart.img of=fatdisk.img \ | |
bs=512 seek=2048 conv=notrunc && \ | |
dd if=mbr-bin of=fatdisk.img \ | |
bs=1 count=446 conv=notrunc && \ | |
dd if=mbr-bin of=fatdisk.img \ | |
bs=1 seek=510 skip=510 count=2 conv=notrunc |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment