嵌入式调试技术(二)——GDB调试应用程序
小狼@http://blog.youkuaiyun.com/xiaolangyangyang
一、gdb在PC机调试本地程序
# gdb helloworld
二、gdb在PC机调试ARM程序
Taget: # ./gdbserver 192.168.1.10:2345 helloworld
Host: # arm-linux-gdb helloworld
> target remote 192.168.1.128:2345
三、coredump使用
在ARM板上: # ulimit -c unlimited
执行应用程序,程序出错时会在当前目录下生成core文件
在PC机上: 将core文件拷贝到PC机上
# arm-linux-gdb ./helloworld ./core