Search code examples
androidandroid-ndkgdbcoredumpndk-gdb

Android Studio generate core dump CMake


I'm trying to generate a core dump for my android studio application. It's written in Java, however I'm trying to generate a coredump due to the fact that the crashes are happening in my native library.

I'm using cmake to configure the native library, not Android.mk.

So when i try to run ndk-gdb i get:

*** Android NDK: Aborting...    .  Stop.
ERROR: Failed to retrieve application ABI from Android.mk.

How do i go about getting a core dump when i'm using CMake in my application? How do I go about running gdb at all?


Solution

  • ndk-gdb doesn't work with CMake. Your best bet will be to use Android Studio's C++ debugging features.