Create Makefile

This commit is contained in:
aramya 2021-06-30 18:18:29 +01:00 committed by GitHub
parent b6a1eb7a99
commit a7daee38c8

20
Makefile Normal file
View File

@ -0,0 +1,20 @@
APMdisk: kernel.elf *txt
dd bs=8M count=2 if=/dev/zero of=APMdisk
parted APMdisk --script mklabel mac mkpart primary hfs+ 32.8KB 100%
sudo chmod +x kpartx.bash
sudo ./kpartx.bash
sudo mkdir /mnt/ppc
sudo mkdir /mnt/boot
sudo cp *txt /mnt/ppc
sudo cp kernel.elf /mnt/boot
sudo umount /mnt/
sudo kpartx -d APMdisk
kernel.elf: boot.elf
powerpc-linux-gnu-ld -Ttext=0x200000 boot.elf -o kernel.elf
boot.elf:
powerpc-linux-gnu-gcc -c boot.S -o boot.elf
clear:
rm APMdisk *elf
clean:
rm APMdisk *elf