You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.
I have compiled libmxpredict.so for Android following the guide found at #7146, but loading it inside an app causes a java.lang.UnsatisfiedLinkError at runtime.
Process: com.happen.it.make.whatsthis, PID: 29304
java.lang.UnsatisfiedLinkError: dlopen failed: cannot locate symbol "_ZN4dmlc2io10FileSystem22ListDirectoryRecursiveERKNS0_3URIEPNSt6__ndk16vectorINS0_8FileInfoENS5_9allocatorIS7_EEEE" referenced by "/data/app/com.happen.it.make.whatsthis-2/lib/arm/libmxnet_predict.so"...
at java.lang.Runtime.loadLibrary(Runtime.java:372)
at java.lang.System.loadLibrary(System.java:1076)
at org.dmlc.mxnet.Predictor.<clinit>(Predictor.java:5)
at com.happen.it.make.whatisit.WhatsApplication.onCreate(WhatsApplication.java:48)
at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1013)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4707)
at android.app.ActivityThread.-wrap1(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1405)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
Minimum reproducible example
I am compiling the WhatsThis sample app from my repo (https://github.com/dmazzoni/WhatsThis.git) with Android Studio 3.0, and running it on a Nexus 5 with Android 6.0.1. The repository includes the libmx_predict.so I recompiled, together with libopenblas.so and libc++_shared.so, whose absence caused linker errors, now solved.
Steps to reproduce
Compile and run the Android application.
The text was updated successfully, but these errors were encountered:
dmazzoni
changed the title
UnsatisfiedLinkError with Amalgamation for Android:
UnsatisfiedLinkError with Amalgamation for Android
Nov 15, 2017
hi,i followed your method, add the line to dmlc-minimum0.cc and recompile another libmxnet_predict.so, still got the error: "can not locate symbol _ZN4dmlc2io10FileSystem22ListDirectoryRecursiveERKNS0_3URIEPNSt6__ndk16vectorINS0_8FileInfoENS5_9allocatorIS7_EEEE" referenced by "/data/app/com.happen.it.make.whatsthis-2/lib/arm/libmxnet_predict.so"." is there any other step you did?
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Description
I have compiled
libmxpredict.so
for Android following the guide found at #7146, but loading it inside an app causes ajava.lang.UnsatisfiedLinkError
at runtime.Environment info
Operating System:
macOS 10.13.1
NDK version:
android-ndk-r14b
Compiler:
arm-linux-androideabi-clang++
MXNet version:
v0.12.0
MXNet commit hash : * 0.12.0 4f2af2d
Error message
Minimum reproducible example
I am compiling the WhatsThis sample app from my repo (https://github.com/dmazzoni/WhatsThis.git) with Android Studio 3.0, and running it on a Nexus 5 with Android 6.0.1. The repository includes the
libmx_predict.so
I recompiled, together withlibopenblas.so
andlibc++_shared.so
, whose absence caused linker errors, now solved.Steps to reproduce
The text was updated successfully, but these errors were encountered: