From b549d087248cd840899ddfc189b7709c7e0aa209 Mon Sep 17 00:00:00 2001 From: WangRunji Date: Thu, 12 Apr 2018 23:44:25 +0800 Subject: [PATCH] Add debug_asm in Makefile --- Makefile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index bf0abd5..454d611 100644 --- a/Makefile +++ b/Makefile @@ -30,13 +30,14 @@ else endif ld := $(prefix)ld +objdump := $(prefix)objdump -.PHONY: all clean run iso kernel build +.PHONY: all clean run iso kernel build debug_asm all: $(kernel) clean: - @rm -r build + @rm -r build target run: $(iso) @qemu-system-$(arch) $(qemu_opts) || [ $$? -eq 11 ] # run qemu and assert it exit 11 @@ -45,6 +46,9 @@ iso: $(iso) build: iso +debug_asm: + @$(objdump) -dS $(kernel) | less + $(iso): $(kernel) $(grub_cfg) @mkdir -p build/isofiles/boot/grub @cp $(kernel) build/isofiles/boot/kernel.bin