mirror of
https://github.com/phil-opp/blog_os.git
synced 2025-12-16 22:37:49 +00:00
Set up GDB
This commit is contained in:
10
Makefile
10
Makefile
@@ -19,7 +19,7 @@ assembly_source_files := $(wildcard src/arch/$(arch)/*.asm)
|
|||||||
assembly_object_files := $(patsubst src/arch/$(arch)/%.asm, \
|
assembly_object_files := $(patsubst src/arch/$(arch)/%.asm, \
|
||||||
build/arch/$(arch)/%.o, $(assembly_source_files))
|
build/arch/$(arch)/%.o, $(assembly_source_files))
|
||||||
|
|
||||||
.PHONY: all clean run iso cargo
|
.PHONY: all clean run debug iso cargo gdb
|
||||||
|
|
||||||
all: $(kernel)
|
all: $(kernel)
|
||||||
|
|
||||||
@@ -28,7 +28,13 @@ clean:
|
|||||||
@rm -rf build
|
@rm -rf build
|
||||||
|
|
||||||
run: $(iso)
|
run: $(iso)
|
||||||
@qemu-system-x86_64 -drive format=raw,file=$(iso)
|
@qemu-system-x86_64 -drive format=raw,file=$(iso) -s
|
||||||
|
|
||||||
|
debug: $(iso)
|
||||||
|
@qemu-system-x86_64 -drive format=raw,file=$(iso) -s -S
|
||||||
|
|
||||||
|
gdb:
|
||||||
|
@rust-os-gdb/bin/rust-gdb "build/kernel-x86_64.bin" -ex "target remote :1234"
|
||||||
|
|
||||||
iso: $(iso)
|
iso: $(iso)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user