User Tools

Site Tools


snippets:gdb

**This is an old revision of the document!**

gdb

  • finish print return value of current function

attach to running process

echo 0 > /proc/sys/kernel/yama/ptrace_scope

thread apply all bt

remote debugging

  • on remote site:
gdbserver --attach :10000 <pid>
  • on local site:
arm-linux-gnueabihf-gdb -x sysroot-file.gdbinit -ex 'target extended-remote <remoteip>:10000' -ex 'set remote exec-file <remote binary>' --args <local binary with debug>
snippets/gdb.1563526493.txt.gz · Last modified: by allspark