From c1d948ce1973d9be37a43718f548776a0061807b Mon Sep 17 00:00:00 2001 From: James Barnett Date: Sat, 1 Sep 2018 12:41:34 +0100 Subject: Add Makefile task to create bootable iso --- Makefile | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 919334d..76fe6e1 100644 --- a/Makefile +++ b/Makefile @@ -11,12 +11,18 @@ build: setup kernel/kernel.c kernel/io/vga/text_mode_display.c kernel/kernel-boo nasm -f elf32 kernel/kernel-bootstrap.asm -o bin/kernel-bootstrap.o $(CC) $(CFLAGS) -c kernel/kernel.c -o bin/kernel.o $(CC) $(CFLAGS) -c kernel/io/vga/text_mode_display.c -o bin/text_mode_display.o - ld -m elf_i386 -T link.ld -o bin/kernel bin/*.o + ld -m elf_i386 -T link.ld -o bin/kernel.bin bin/*.o clean: rm -f bin/* + rm -f boot-iso/boot/kernel.bin + rm -f tinyOS.iso run: - qemu-system-i386 -kernel bin/kernel + qemu-system-i386 -kernel bin/kernel.bin -build-and-run: build run \ No newline at end of file +build-and-run: build run + +iso: build + cp bin/kernel.bin boot-iso/boot/ + grub-mkrescue -o tinyOS.iso boot-iso/ \ No newline at end of file -- cgit v1.2.3