diff options
author | dzwdz | 2021-07-18 16:47:38 +0200 |
---|---|---|
committer | dzwdz | 2021-07-18 16:47:38 +0200 |
commit | 656e1407f440e9b7665d2e910a7fa2f5d851a1bd (patch) | |
tree | 169ff2b2a557cb0864c2eefc273b6f1fb805e8fa | |
parent | b38298319411965cbb7e9ed1312b24ba36cc7c44 (diff) |
minor Makefile readibility tweaks
-rw-r--r-- | Makefile | 21 |
1 files changed, 12 insertions, 9 deletions
@@ -11,29 +11,32 @@ define from_sources $(patsubst src/%.c,out/obj/%.c.o,$(shell find $(1) -type f -name '*.c')) endef + out/boot.iso: out/fs/boot/kernel.bin out/fs/boot/grub/grub.cfg out/fs/boot/init + @echo grub-mkrescue -o $@ out/fs/ -out/fs/boot/grub/grub.cfg: grub.cfg +out/fs/boot/kernel.bin: src/kernel/linker.ld $(call from_sources, src/kernel/) @mkdir -p $(@D) - cp $< $@ + $(CC) $(LFLAGS) -T $^ -o $@ + grub-file --is-x86-multiboot $@ out/fs/boot/init: src/test_module @mkdir -p $(@D) - cp $< $@ + @cp $< $@ -out/fs/boot/kernel.bin: src/kernel/linker.ld $(call from_sources, src/kernel/) +out/fs/boot/grub/grub.cfg: grub.cfg @mkdir -p $(@D) - $(CC) $(LFLAGS) -T $^ -o $@ - grub-file --is-x86-multiboot $@ + @cp $< $@ + out/obj/%.s.o: src/%.s @mkdir -p $(@D) - $(AS) $^ -o $@ + @$(AS) $^ -o $@ out/obj/%.c.o: src/%.c @mkdir -p $(@D) - $(CC) $(CFLAGS) -c $^ -o $@ + @$(CC) $(CFLAGS) -c $^ -o $@ .PHONY: boot debug lint clean @@ -42,7 +45,7 @@ boot: out/boot.iso debug: out/boot.iso qemu-system-i386 $< $(QFLAGS) -s -S & - sleep 1 + @sleep 1 gdb lint: |