Eric Agredo Eric Agredo - 4 months ago 27
Java Question

Unsatisfied linkerror aarch64 Samsung Galaxy S6

Hi I have been trying to test my code on my Samsung Galaxy S6, but it keeps crashing because of an Unsatisfied linkerror. Here is the error message:

AndroiddRuntime: FATAL EXCEPTION: main
Process: com.example.ericagredo.marvinproject, PID: 14982
java.lang.UnsatisfiedLinkError: Native library (com/sun/jna/android-aarch64/libjnidispatch.so) not found in resource path (.)
at com.sun.jna.Native.loadNativeDispatchLibraryFromClasspath(Native.java:866)
at com.sun.jna.Native.loadNativeDispatchLibrary(Native.java:826)
at com.sun.jna.Native.<clinit>(Native.java:140)
at com.sun.jna.Native.loadLibrary(Native.java:481)
at com.emotiv.iedk.Edk.<clinit>(Edk.java:15)
at com.example.ericagredo.marvinproject.MainActivity.onCreate(MainActivity.java:52)
at android.app.Activity.performCreate(Activity.java:6374)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1119)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2767)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2879)
at android.app.ActivityThread.access$900(ActivityThread.java:182)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1475)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6141)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)


I am using jna.jar as a library and I believe that's where the problem is stemming from. When I go into the folders, there is no folder named android-aarch64 and I am not sure how to get it.

Here are the folders in jna.jar:
Screenshot

Answer

Not entirely sure you need a JAR file.

In the Emotiv Android examples, there is this Gradle dependency.

compile 'com.emotiv.sdk:community:3.3.+@aar'