I'm having trouble debugging my own code using the Android NDK.
While the application is running, I start ndk-gdb , and the result is that gdb loses connection with the device and the application on the device crashes.
The same thing happens with the device (Samsung Galaxy 10.1), and with the emulator. Mac OS X is installed on the host computer. The native part of the application consists of several .so libraries using ndk-build clean all NDK_DEBUG=1
I have connected the gdb output below.
Any help would be greatly appreciated.
Edit: Maybe the problem is due to a cp command error? And the empty line "Using gdb setup init:"?
$NDK/ndk-gdb --verbose Android NDK installation path: /Users/flavio/Documents/android-sdk-mac_x86/ndk/android-ndk-r7 Using default adb command: /Users/flavio/Documents/android-sdk-mac_x86/platform-tools/adb ADB version found: Android Debug Bridge version 1.0.29 Using final ADB command: '/Users/flavio/Documents/android-sdk-mac_x86/platform-tools/adb' Using auto-detected project path: /Users/flavio/MacDevel/nTrack/trunk/n-Track_EX/Android/AndroidTesting Found package name: com.ntrack.ntrack ABIs targetted by application: armeabi Device API Level: 12 Device CPU ABIs: armeabi-v7a armeabi Compatible device ABI: armeabi Found debuggable flag: false Found gdbserver under libs/armeabi, assuming app was built with NDK_DEBUG=1 Found device gdbserver: /data/data/com.ntrack.ntrack/lib/gdbserver Using gdb setup init: Using toolchain prefix: /Users/flavio/Documents/android-sdk-mac_x86/ndk/android-ndk-r7/toolchains/arm-linux-androideabi-4.4.3/prebuilt/darwin-x86/bin/arm-linux-androideabi- Using app out directory: ./obj/local/armeabi Found data directory: '/data/data/com.ntrack.ntrack' Found running PID: 2302 Launched gdbserver succesfully. Setup network redirection
source share