Only build files that have changed
This commit is contained in:
parent
7197016ae7
commit
0904ad4d99
15
Makefile
15
Makefile
|
@ -1,24 +1,23 @@
|
|||
TARGET = foxdos
|
||||
|
||||
FILES = src/int21.s \
|
||||
src/kernel.s
|
||||
src/kernel.s
|
||||
|
||||
.PHONY: all qemu clean
|
||||
all: prepare boot kernel img
|
||||
all: obj/boot.o obj/kernel.o $(TARGET)
|
||||
|
||||
qemu: all
|
||||
qemu-system-i386 -fda $(TARGET)
|
||||
|
||||
prepare:
|
||||
mkdir -p obj
|
||||
|
||||
boot: src/boot.s
|
||||
obj/boot.o: src/boot.s
|
||||
@mkdir -p obj
|
||||
nasm -I. -Isrc src/boot.s -o obj/boot.o
|
||||
|
||||
kernel: $(FILES)
|
||||
obj/kernel.o: $(FILES)
|
||||
@mkdir -p obj
|
||||
nasm -I. -Isrc src/kernel.s -o obj/kernel.o
|
||||
|
||||
img:
|
||||
$(TARGET):
|
||||
cat obj/boot.o obj/kernel.o > $(TARGET)
|
||||
|
||||
clean:
|
||||
|
|
Loading…
Reference in New Issue