summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile12
1 files changed, 9 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 8bb5127..2a6fc61 100644
--- a/Makefile
+++ b/Makefile
@@ -15,11 +15,17 @@ irq.o: irq.asm
kernel.o: kernel.asm
$(nasm) -o kernel.o kernel.asm
-$(TARGET): irq.o io.o kernel.o boot.o
- ld -g -m elf_i386 -T link.ld -o $(TARGET) boot.o io.o irq.o kernel.o
+ctest.o: ctest.c
+ gcc -c -o ctest.o -m32 -O3 -nostdlib -nostdinc \
+ -fno-builtin -fno-stack-protector \
+ -nostartfiles -nodefaultlibs \
+ -Wall -Wextra \
+ ctest.c
+$(TARGET): ctest.o irq.o io.o kernel.o boot.o
+ ld -g -m elf_i386 -T link.ld -o $(TARGET) boot.o io.o irq.o ctest.o kernel.o
run: $(TARGET)
- qemu-system-i386 -m 2M -kernel $(TARGET)
+ qemu-system-i386 -m 8M -kernel $(TARGET)
debug: $(TARGET)
qemu-system-i386 -d int,guest_errors -no-reboot -s -S -m 8M -kernel $(TARGET) &