错误日志:
"nativeLibraryDirectories=[/data/app/com.lukouapp-1/lib/arm64, /vendor/lib64, /system/lib64]]] couldn't find "libxxxx.so"
问题原因:64位机器默认去查找arm64-v8a目录下是否有合适的64位库,如果没有则回去libs下查找32位的库,而fresco的draw-pipeline太完善了考虑了64位的机器所以他的arm64-v8a下有so库,对应的系统就创建了lib64的文件,而不再去找32位的库。
解决办法一:
*修改前:
Edit your build.gradle file as follows:
android {
// rest of your app's logic
splits {
abi {
enable true
reset() include 'x86', 'x86_64', 'arm64-v8a', 'armeabi-v7a', 'armeabi'
universalApk false
}
}
}
*修改后:
Edit your build.gradle file as follows:
android {
// rest of your app's logic
splits {
abi {
enable true
reset() include 'x86', 'x86_64', 'armeabi-v7a', 'armeabi'
universalApk false
}
}
}
注意:如果加入上面代码还不行 ,可以注释掉下面这行(如果你的主要工程目录没有加入lib和jar的话)
dependencies {
// compile fileTree(include: ['*.jar'], dir: 'libs')
}
解决办法二:
也是通过修改gradle文件,
*修改前:
defaultConfig {
applicationId "com.richinfo.travel"
minSdkVersion 10
targetSdkVersion 22
versionCode 3
versionName "1.0.2"
buildConfigField "boolean", "LOG_DEBUG", "true"
consumerProguardFiles 'proguard-file.txt'
manifestPlaceholders =[UMENG_CHANNEL_VALUE: "local"]
}
*修改后:
defaultConfig {
applicationId "com.richinfo.travel"
minSdkVersion 14
targetSdkVersion 22
versionCode 3
versionName "1.0.2"
buildConfigField "boolean", "LOG_DEBUG", "true"
consumerProguardFiles 'proguard-file.txt'
manifestPlaceholders = [UMENG_CHANNEL_VALUE: "local"]
ndk {
abiFilters "armeabi", "armeabi-v7a", "x86", "mips"
}}