Issue
i'm trying to add some lib (.jar & .so)to my multidex project in android studio.
when i add only a few jars to the project everything works fine. in case i add more and more jars (other libs) i'm getting this error:
java.lang.UnsatisfiedLinkError:
dalvik.system.PathClassLoader[DexPathList[[zip file
"/data/app/com.test.digital.ocrtest-2/base.apk"],nativeLibraryDirectories=[/data/app/com.test.digital.ocrtest-2/lib/arm,
/data/app/com.test.digital.ocrtest-2/base.apk!/lib/armeabi-v7a,
/vendor/lib, /system/lib]]] couldn't find
"libScanovatePassportAndIDLSDK_CPP.so"
any idea how can I tell to the compiler to generate jar and so in same dex?
Solution
If some of the extra JARs bring native libraries for armeabi-v7a, while your libScanovatePassportAndIDLSDK_CPP.so was only built for armeabi, the installer will extract a wrong set of libraries. The fix is not to add more copies of .so, but rather strip away the other ABIs. In gradle, you can use splits.
Answered By - Alex Cohn
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.