A binary with debug symbols with the Android NDK

First go into the Android.mk file in your jni folder and add this line:
LOCAL_CFLAGS += -g

This is going to enable the debug compile option. You might have a separate option for logging more data.

Next go into Application.mk and uncomment this line:
APP_OPTIM := debug

(or add it if it isnt there)

This should be sufficient. Now when you run the ndk-build (You can run ndk-build V=1 to enable the verbose option), you should get the debuggable binaries. For some reason the binary I get in the libs/armeabi folder is not the debuggable one, this one has its debug options stripped out. To get the debug one grab it from obj/local/armeabi.

Comments

  1. THANKS!!!
    Your remark about the obj/local/armeabi saved me a lot of time!

    ReplyDelete
  2. Cool and I have a dandy give: How To Become A House Renovation prefab home addition

    ReplyDelete

Post a Comment

Popular posts from this blog

endmenu in different file than menu?

Multi Threading in Android