How do I debug native code of samples on Android in Eclipse?

asked 2014-01-18 17:14:42 -0600

IZ73 gravatar image

I am using Eclipse and trying to step through the native portions of the NDK OpenCV 2.4.8 samples, e.g. "T2 - Mixed Processing". I can both Run as Android App and Debug as Android App, and in the latter case I hit breakpoints in the Java parts (e.g. but not in the C++ parts (e.g. jni_part.cpp). I tried Debug as Android Native Application but nothing happened and I saw no new messages in LogCat.

What do I need to do to be able to hit the C++ breakpoints?

Thank you

edit retag flag offensive close merge delete


I am also trying to figure it out but I found that by setting everything with android-9 works. My configuration is:

p.s when I will have the solution i will tell you.

andrei.toader gravatar imageandrei.toader ( 2014-02-05 16:14:23 -0600 )edit

Ok, I figured it out. It's like this. Configure everywhere the same android version. AndroidManifest - e.g 14 my case. - 14 and same 14 - try to use the same configuration from the pastebin (debug flag must be set to true). It should work. I tested for version android-16 also and it works.

andrei.toader gravatar imageandrei.toader ( 2014-02-05 16:46:12 -0600 )edit