0

I'm trying to debug native application in Eclipse. Unfortunately, when I run "Debug As-> Android Native Application" I see the following errors in the console:

[2014-09-10 21:03:48 - GenderDetector] Verify if the application was built with NDK_DEBUG=1
[2014-09-10 21:04:16 - GenderDetector] gdbserver output:
[2014-09-10 21:04:16 - GenderDetector] run-as: Package 'com.opencv.genderdetector' is unknown

If I try to add "NDK_DEBUT=1" to the ndk-build command I see the following errors:

[armeabi-v7a] Gdbserver      : [arm-linux-androideabi-4.9] libs/armeabi-v7a/gdbserver
install: cannot stat ‘/home/yury/software/android-ndk/prebuilt/android-arm/gdbserver/gdbserver’: No such file or directory
make: *** [libs/armeabi-v7a/gdbserver] Error 1

Could someone please explain what I'm doing wrong?

2
  • Possibly related: Debugging Android NDK native apps. Commented Sep 13, 2014 at 12:56
  • Also, consider this post Some regression was introduced with respect to file permissions in Android 4.3 (patched in Android 4.4). Samsung still seems to experience problems. Make sure you are not in this situation. Commented Dec 23, 2014 at 19:41

3 Answers 3

2

Here is a steps that may help you :

  1. Check if /home/yury/software/android-ndk/prebuilt/android-arm/gdbserver/gdbserver is exsits
  2. Check if it has execution permission.
  3. Add this path to your environment variables this maybe will help.
  4. Make sure your android-ndk folder is complete as it comes from google when you download.

Regards.

Sign up to request clarification or add additional context in comments.

Comments

0

Build your application like this : ndk-build NDK_DEBUG:=1 APP_OPTIM:=debug This enables the debug flag and also creates symbol files used by the debugger. You will see 2 files gdbserver.so and gdb.setup created within jni/libs folder. After this is done, you are good to debug as native application.

Comments

0

I meet this error when I use android-ndk-r10. After I uses android-ndk-r10e, this error disappear.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.