2015년 11월 10일 화요일

gdbserver

gdbserver 실행 (Target)
# gdbserver --attach :5039 <PID>
Attached; pid = 7148
Listening on port 5039
 
 또는
 
# gdbserver :5039 <BINARY PATH>
Process xxx created; pid = 6232
Listening on port 5039
 
 
gdb 실행 (Host)
$ gdb-multiarch
(gdb) set arch arm
(gdb) file <BINARY PATH>
(gdb) target remote [gdbserver ip]:5039
 
 
참고
https://sourceware.org/gdb/wiki/BuildingCrossGDBandGDBserver