我在Sinch得到了Bellow错误。 它在某些设备中的问题。
Process: com.reach.communications, PID: 14029
java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/com.reach.communications-1/base.apk"],nativeLibraryDirectories=[/data/app/com.reach.communications-1/lib/arm64, /vendor/lib64, /system/lib64]]] couldn't find "libsinch-android-rtc.so"
at java.lang.Runtime.loadLibrary(Runtime.java:366)
at java.lang.System.loadLibrary(System.java:988)
at com.sinch.android.rtc.internal.client.DefaultSinchClient.<clinit>(DefaultSinchClient.java:76)
at com.sinch.android.rtc.internal.client.InternalSinchClientFactory.createSinchClient(InternalSinchClientFactory.java:19)
at com.sinch.android.rtc.DefaultSinchClientBuilder.build(DefaultSinchClientBuilder.java:95)
at com.reach.communications.ui.sinch.SinchService.start(SinchService.java:146)
at com.reach.communications.ui.sinch.SinchService.access$200(SinchService.java:19)
at com.reach.communications.ui.sinch.SinchService$SinchServiceInterface.startClient(SinchService.java:50)
at com.reach.communications.ui.Fragment3.setView(Fragment3.java:91)
at com.reach.communications.ui.Fragment3.onCreateView(Fragment3.java:78)
at android.app.Fragment.performCreateView(Fragment.java:2053)
at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:895)
at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1068)
at android.app.BackStackRecord.run(BackStackRecord.java:840)
at android.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1455)
at android.app.FragmentManagerImpl$1.run(FragmentManager.java:447)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5273)
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:908)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:703)
请帮我解决一下。我正在使用android studio。
答案 0 :(得分:2)
试试这个:
<强>的build.gradle 强>
<Context>
<WatchedResource>WEB-INF/web.xml</WatchedResource>
<Manager pathname="" />
<Parameter name="shiroConfigLocations" value="file:/var/isis-config/shiro.ini" override="false" />
<Parameter name="isis.config.dir" value="/var/isis-config/" override="false" />
<Parameter name="wicket.configuration" value="deployment" override="false" />
</Context>
要做的另一件重要事情
您需要在android
{
compileSdkVersion 23
buildToolsVersion "23.0.3"
defaultConfig
{
...
//important code, write in target API 22
minSdkVersion 15
targetSdkVersion 22
...
}//end defaultConfig
sourceSets
{
main
{
...
jniLibs.srcDirs = ['src/main/jniLibs']
assets.srcDirs = ['src/main/assets/']
aidl.srcDirs = ['src/main/aidl/']
...
}
// Move the tests to tests/java, tests/res, etc...
instrumentTest.setRoot('tests')
// Move the build types to build-types/<type>
// For instance, build-types/debug/java, build-types/debug/AndroidManifest.xml, ...
// This moves them out of them default location under src/<type>/... which would
// conflict with src/ being used by the main source set.
// Adding new build types or product flavors should be accompanied
// by a similar customization.
debug.setRoot('build-types/debug')
release.setRoot('build-types/release')
}//end sourceSets
...
...
}//end android
中创建一个新文件夹,并在其中添加* .SO库。
答案 1 :(得分:0)
将libsinch-android-rtc.so
lib64版本添加到/libs
。