0

Here I am providing the error while compiling 'imsdroid':

Native code library failed to load.
dlopen failed: library "/data/data/org.doubango.imsdroid/lib/libtinyWRAP.so" not found



  Process: org.doubango.imsdroid, PID: 9195
    > java.lang.UnsatisfiedLinkError: Native method not found org.doubango.tinyWRAP.tinyWRAPJNI.swig_module_init:()V
    > at org.doubango.tinyWRAP.tinyWRAPJNI.swig_module_init(Native Method)
    > at org.doubango.tinyWRAP.tinyWRAPJNI.<clinit>(tinyWRAPJNI.java:554)
    > at org.doubango.tinyWRAP.XcapCallback.<init>(XcapCallback.java:0)
    > at org.doubango.imsdroid.Services.Impl.XcapService$MyXcapCallback.<init>(XcapService.java:0)
    > at org.doubango.imsdroid.Services.Impl.XcapService.<init>(XcapService.java:93)
    > at org.doubango.imsdroid.Services.Impl.ServiceManager.<clinit>(ServiceManager.java:91)
    > at org.doubango.imsdroid.Main.<init>(Main.java:132)
    > at java.lang.Class.newInstanceImpl(Native Method)
    > at java.lang.Class.newInstance(Class.java:1208)
    > at android.app.Instrumentation.newActivity(Instrumentation.java:1068)
    > at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2288)
    > at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493)
    > at android.app.ActivityThread.access$800(ActivityThread.java:166)
    > at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283)
    > at android.os.Handler.dispatchMessage(Handler.java:102)
    > at android.os.Looper.loop(Looper.java:136)
    > at android.app.ActivityThread.main(ActivityThread.java:5584)
    > at java.lang.reflect.Method.invokeNative(Native Method)
    > at java.lang.reflect.Method.invoke(Method.java:515)
    > at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268)
    > at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084)
    > at dalvik.system.NativeStart.main(Native Method)

Can anyone give me some suggestions to overcome this error?

Cœur
  • 37,241
  • 25
  • 195
  • 267
Akhter Al Amin
  • 852
  • 1
  • 11
  • 25

2 Answers2

0

Your application tries to load a native library ,Check to see if this file exists . This problem most often shows up because the library does not exist, or can not be located by the JVM.The structure of these Exception class is here ,

public class UnsatisfiedLinkErrorExample {

     // Define a method that is defined externally.
     native void CFunction();

     // Load an external library, called "clibrary".
     static {
          System.loadLibrary("clibrary");
     }

     public static void main(String argv[]) {
          UnsatisfiedLinkErrorExample example = new UnsatisfiedLinkErrorExample();
          example.CFunction ();
     }
}

For more detailed information you can see here Exception

Shubham Sharma
  • 2,763
  • 5
  • 31
  • 46
0

IMSDroid uses Doubango backend support library as a JNI Lib dependency. You must follow steps Building Doubango to setup a Doubango Compilation on a linux machine to generate libTinyWRAP.so

Its a little tricky and I have worked on it for a whole year since I didn't initially have much background with linux make files etc. The instructions and documentation are also limited. So if you are a beginner, you are looking at a lot of sleepless nights and online consultation before you get it to work how you want.

Make no mistake, IMSDroid is stable and works fully, and has awesome features and is pretty reliable. Doubango library is also pretty good, but doesn't come with any concrete documentation. It's one thing that's still relevant for making video call even today!

This error that you are seeing is obviously because your libTinyWRAP.so file is not in the folder it is supposed to be and when you install the app, this library was not copied over to required lib folder on the device.

Use Shift+Ctrl+F in Android Studio, and look for loadLibrary, which should be inside android-ngn-stack or inside some Engine.java or NgnEngine.java. Your error is coming from there.

BLH
  • 123
  • 6