From ef78de447ff436a1d8ea2488a21d6710fa0832e9 Mon Sep 17 00:00:00 2001 From: Mathieu Maret Date: Tue, 26 Jan 2021 17:58:33 +0100 Subject: [PATCH] Improve make target names --- Makefile | 12 ++++++++---- README.md | 2 +- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index bd84d3c..c8fe12f 100644 --- a/Makefile +++ b/Makefile @@ -44,14 +44,15 @@ arch/$(ARCH)/irq_handler.o:arch/$(ARCH)/irq_handler.c $(CC) "-I$(PWD)" -c "$<" $(CFLAGS) -o "$@" -self_test: CFLAGS += -DRUN_TEST -DDEBUG -self_test: clean kernel +test: CFLAGS += -DRUN_TEST +test: clean kernel qemu-system-x86_64 -kernel kernel -serial stdio -test:kernel +run:kernel qemu-system-x86_64 -kernel $< -debug: CFLAGS += $(DEBUG_FLAGS) + +debug: CFLAGS += $(DEBUG_FLAGS) -DRUN_TEST debug: CXXFLAGS += $(DEBUG_FLAGS) debug:kernel kernel.sym #qemu-system-x86_64 -s -S -kernel kernel& @@ -59,6 +60,9 @@ debug:kernel kernel.sym #gdb -s kernel.sym -ex "target remote localhost:1234" -ex "dir core:driver:arch/$(ARCH))'" gdb -x debug.gdb +debug_test: CFLAGS += $(DEBUG_FLAGS) -DRUN_TEST +debug_test: debug + clean: $(RM) kernel $(asmobj) $(cobj) $(deps) fd.iso kernel.sym $(RM) -r isodir diff --git a/README.md b/README.md index 958c10a..9a6d44e 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ To generate iso image # Run it - `make test` + `make run` or