blob: 0f78ee6ceb6f08026dca2fe6fa30cebc4c28ff81 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
#!/bin/sh
# Set this environment variable to override the default debugger.
#
[ -z "$SERENITY_KERNEL_DEBUGGER" ] && SERENITY_KERNEL_DEBUGGER="gdb"
# The QEMU -s option (enabled by default in ./run) sets up a debugger
# remote on localhost:1234. So point our debugger there, and inform
# the debugger which binary to load symbols, etc from.
#
exec $SERENITY_KERNEL_DEBUGGER \
-ex "file $(dirname "$0")/../Build/${SERENITY_ARCH:-i686}/Kernel/Kernel" \
-ex 'set arch i386:intel' \
-ex 'target remote localhost:1234' \
-ex "source $(dirname "$0")/serenity_gdb.py" \
"$@"
|