Makefile update

pull/22/head
E. Almqvist 3 years ago
parent 205fcb9b80
commit b6b03ef8f7
  1. 2
      .gitignore
  2. 10
      Makefile

2
.gitignore vendored

@ -1,3 +1,5 @@
bin/ bin/
*.bin *.bin
*.o *.o
os-image
*.dis

@ -1,12 +1,12 @@
all: os-image all: os-image
run: all run: all
qemu-system-x86_64 bin/os-image qemu-system-x86_64 os-image
os-image: bootloader.bin kernel.bin os-image: bootloader.bin kernel.bin
cat $^ > bin/os-image cat $^ > os-image
kernel.bin: bin/kernel_entry.o bin/kernel.o kernel.bin: kernel_entry.o kernel.o
ld -o kernel.bin -Ttext 0x1000 $^ --oformat binary ld -o kernel.bin -Ttext 0x1000 $^ --oformat binary
kernel.o : src/kernel/kernel.c kernel.o : src/kernel/kernel.c
@ -19,7 +19,7 @@ bootloader.bin : src/bootloader/bootloader.asm
nasm $< -f bin -o $@ nasm $< -f bin -o $@
clean: clean:
rm -fr bin/*.bin bin/*.dis bin/*.o bin/os-image bin/*.map rm -fr *.bin *.dis *.o os-image *.map
kernel.dis : bin/kernel.bin kernel.dis : kernel.bin
ndisasm -b 32 $< > $@ ndisasm -b 32 $< > $@

Loading…
Cancel
Save