How to Debug native code using ndk-gdb

风流意气都作罢 提交于 2019-12-06 03:35:07

The commands are the same as in gdb. A basic primer:

  • Set a breakpoint by entering b <function name> or b <file>:<line number>
  • step into functions by typing s
  • go to next line by typing n
  • continue execution with c
  • print a variable or expression value with print <exp>
  • repeat the last typed command by just hitting enter

You can find much more comprehensive gdb tutorials online. I personally have a gdb cheatsheet printed out and posted on my wall. This should be enough to get you started.

this tutorial will show you exactly how to debugging with ndk-gdb in eclipse.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!