场景
在集成第三方模块时,需要引入一些so文件,运行项目报错,
More than one file was found with OS independent path 'lib/armeabi-v7a/libnms.so'
解决方案
在启动模块(通常是app模块)的build.gradle中添加如下代码:
android {
...
// Fix: More than one file was found
packagingOptions {
pickFirst 'lib/armeabi-v7a/libnms.so'
}
}