mirror of
https://github.com/Fennix-Project/Userspace.git
synced 2025-05-25 22:14:28 +00:00
Add gdb for init.elf
This commit is contained in:
parent
607d0dc048
commit
d0ec077c09
40
.vscode/launch.json
vendored
Normal file
40
.vscode/launch.json
vendored
Normal file
@ -0,0 +1,40 @@
|
||||
{
|
||||
"version": "0.2.0",
|
||||
"configurations": [
|
||||
{
|
||||
"name": "/system/init.elf",
|
||||
"type": "cppdbg",
|
||||
"request": "launch",
|
||||
"program": "${workspaceRoot}/out/system/init.elf",
|
||||
"cwd": "${workspaceRoot}",
|
||||
"args": [],
|
||||
"targetArchitecture": "x64",
|
||||
"MIMode": "gdb",
|
||||
"miDebuggerPath": "/usr/bin/gdb",
|
||||
"miDebuggerArgs": "",
|
||||
"externalConsole": false,
|
||||
"additionalSOLibSearchPath": "${workspaceRoot}",
|
||||
"customLaunchSetupCommands": [
|
||||
{
|
||||
"text": "target remote localhost:1234",
|
||||
"description": "Connect to QEMU remote debugger"
|
||||
}
|
||||
],
|
||||
"setupCommands": [
|
||||
{
|
||||
"description": "Enable pretty-printing for gdb",
|
||||
"text": "-enable-pretty-printing",
|
||||
"ignoreFailures": true
|
||||
},
|
||||
{
|
||||
"text": "set breakpoint pending on",
|
||||
"description": "Make breakpoint pending on future shared library load."
|
||||
},
|
||||
{
|
||||
"text": "file ${workspaceRoot}/out/system/init.elf",
|
||||
"description": "Load binary."
|
||||
},
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
@ -48,6 +48,11 @@ else ifeq ($(OSARCH), aarch64)
|
||||
CFLAGS += -pipe
|
||||
endif
|
||||
|
||||
ifeq ($(DEBUG), 1)
|
||||
CFLAGS += -DDEBUG -ggdb3 -O0 -fdiagnostics-color=always -fverbose-asm
|
||||
LDFLAGS += -ggdb3 -O0
|
||||
endif
|
||||
|
||||
build: $(FILENAME)
|
||||
$(OBJDUMP) -d $(FILENAME) > file_dump.map
|
||||
mv $(FILENAME) ../../../out/system/$(FILENAME)
|
||||
|
Loading…
x
Reference in New Issue
Block a user