Debugging an Android NDK application in Eclipse
Debugging at terminals with GDB or CGDB is cumbersome for developers who are used to the graphical development tools. With Android Development Tools (ADT) 20.0.0 or above, debugging NDK application in Eclipse is fairly easy.
Getting ready
Make sure you have ADT 20.0.0 or above installed. If not, please refer to recipes in Chapter 1, Hello NDK, that explain how to set your environment up.
Make sure you have configured the NDK path in Eclipse. In addition, you are expected to have built and run at least one Android NDK application before reading this recipe. If not, please go through the Building Android NDK Application at Eclipse recipe.
How to do it...
The following steps create a sample Android project and debug it using Eclipse:
We'll use the project created in the Building Android NDK application at Eclipse recipe. If you don't have the project open in your Eclipse IDE, click on File | Import. Select Existing Projects into Workspace under General...