UnsatisfiedLinkError:dlopen 失败:找不到库 [英] UnsatisfiedLinkError: dlopen failed: library not found

查看:43
本文介绍了UnsatisfiedLinkError:dlopen 失败:找不到库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用了 Wikitude SDK v4,当我启动我的活动时出现此错误.我的 IDE 是 Android Studio 1.5 和 targetSDK 22

I used the Wikitude SDK v4 and when i launch my Activity i get this error. My IDE is Android Studio 1.5 and targetSDK 22

Caused by: java.lang.UnsatisfiedLinkError: dlopen failed: library "/data/data/xxxx/libarchitect.so" not found.

我的 app/libs 文件夹中有 wikitudesdk.jar,这是我的 gradle 文件:

I have the wikitudesdk.jar in my app/libs folder and here is my gradle file:

apply plugin: 'com.android.application'

android {
compileSdkVersion 23
buildToolsVersion "23.0.2"

defaultConfig {
    applicationId "xxxx"
    minSdkVersion 11
    targetSdkVersion 23
    versionCode 2
    versionName "2"
}
buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}

packagingOptions {
    exclude 'META-INF/LICENSE.txt'
    exclude 'META-INF/NOTICE.txt'
    exclude 'META-INF/maven/commons-io/commons-io/pom.xml'
    exclude 'META-INF/maven/commons-io/commons-io/pom.properties'
    }
}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:23.1.1'
compile 'com.android.support:support-v4:23.1.1'
compile 'com.android.support:recyclerview-v7:23.1.1'
compile 'com.android.support:gridlayout-v7:23.1.1'
...

}

最好的保护

推荐答案

你可以试试System.load("data/data/yourpackagename/lib/soname.so")(使用真实路径到您的 .so 文件).

You can try System.load("data/data/yourpackagename/lib/soname.so") (using the real path to your .so file).

这篇关于UnsatisfiedLinkError:dlopen 失败:找不到库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆