30

I'm Using Android studio 2.2 and Android.mk file followed this

https://developer.android.com/studio/debug/index.html

c++ files located inside Android module and not in the calling application. I added to the module the following:

 externalNativeBuild {
        ndkBuild {
            path 'jni/Android.mk'
        }
    }

there are no errors when I build the project and I can add breakpoints in my java files, but I keep getting No symbol directories found when I try to attach native debugger. when I don't get the error the debugger never stop in any breakpoints inside c++ module files.

I'm using buildToolsVersion "25.0.0", I saw this https://code.google.com/p/android/issues/detail?id=202611 still the same error

any idea how to overcome this?

Zoe
  • 27,060
  • 21
  • 118
  • 148
BoazGarty
  • 1,410
  • 4
  • 18
  • 38
  • Have you tried [this solution](https://stackoverflow.com/questions/41822747/debugging-c-native-libary-modules-not-working-with-android-studio-cmake-used#answer-41867982) or [this solution](https://stackoverflow.com/questions/32584177/native-debug-android-studio#answer-42382393)? – Bernardo Rocha Jul 19 '17 at 12:35

1 Answers1

0

I've managed to solve this by doing build APK under Build->build APK. after the apk was built I run the application as usual and debugger hits breakpoints inside c++ code.

it seems to be resolve in newer Android studio versions.

BoazGarty
  • 1,410
  • 4
  • 18
  • 38