A crash will happen, if my shared library compiled with NDK for Android M

43 views
Skip to first unread message

ulim...@gmail.com

unread,
Sep 18, 2015, 10:37:35 AM9/18/15
to android-ndk
 Description :
 
1. my apk will crash,if it uses a shared library(libX.so) compiling with NDK ,  while it runs ok if the shared library compile in Android source code environment
2. the Crash stack always be same everytime,and if I add a variable Declaration in the class defined in Acodec.h(my codes), the crash stack would change.
 
3. my shared library(libX.so)is used for hardware encode/decode, and I use the API of MediaCodec (MediaCodc.h in libstagefright.so), it will be ok, and if my libX.so contains MediaCodec.cpp and Acodec.cpp, using the API of IOMX, the libX.so must crash
 
4. I decomplied the libX.so compiled with NDK and Android source code environment respectively,they are different

NDK version:
android-ndk-r10d
 
Consultation
     the difference of the defualt option of compiler in android Source code and NDK
     the reasons may result in the crash
 
 
 
the attachment : left is my code, right is android source code
 
Des.JPG
Reply all
Reply to author
Forward
0 new messages