Skip to content

Commit

Permalink
gdb: require gdb-multiarch for -g
Browse files Browse the repository at this point in the history
Since `gdb` likely was only configured for the those triple.
  • Loading branch information
nickdesaulniers committed Jun 16, 2020
1 parent b0f17a2 commit 97b5266
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ Optional parameters:
Invokes 'set -x' for debugging the script.

-g | --gdb:
Add '-s -S' to the QEMU invocation to allow debugging via GDB.
Add '-s -S' to the QEMU invocation to allow debugging via GDB (will invoke
`$GDB_BIN` env var else `gdb-multiarch`).

-h | --help:
Prints this message then exits.
Expand Down
2 changes: 1 addition & 1 deletion boot-qemu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ function invoke_qemu() {
-s -S &
QEMU_PID=$!
green "Starting GDB..."
gdb "${KBUILD_DIR}/vmlinux" -ex "target remote :1234"
"${GDB_BIN:-gdb-multiarch}" "${KBUILD_DIR}/vmlinux" -ex "target remote :1234"
red "Killing QEMU..."
kill -9 "${QEMU_PID}"
wait "${QEMU_PID}" 2>/dev/null
Expand Down

0 comments on commit 97b5266

Please sign in to comment.