Files
low-level-programming/rust_kernel/Makefile
2015-10-26 03:04:21 -07:00

21 lines
404 B
Makefile

all: run_kernel
kernel.bin: multiboot2_header.asm rust_boot.asm linker.ld
nasm -f elf64 multiboot2_header.asm
nasm -f elf64 rust_boot.asm
ld -n -o kernel.bin -T linker.ld multiboot2_header.o rust_boot.o
os.iso: kernel.bin
cp kernel.bin isofiles/
grub-mkrescue -o os.iso isofiles
run_kernel: os.iso
qemu-system-x86_64 -hda os.iso
.PHONY: clean
clean:
rm -f *.o
rm -f kernel.bin
rm -f os.iso