[英]Android how to exclude certain folder from apk file
I create android project and add compile dependencies that have other platforms tools/files/libs and I need to remove(exclude) this file from my .apk file. 我创建了一个android项目并添加了具有其他平台工具/文件/库的编译依赖项,我需要从.apk文件中删除(排除)此文件。 You can see the folder I want to remove on this screenshot:
您可以在此屏幕截图上看到我要删除的文件夹:
android {
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'),
'proguard-rules.pro'
}
}
...
}
Also, keep in mind that that if you go the proguard route, then you need to re-evaluate your dependencies and make special exceptions for any code that uses reflection. 另外,请记住,如果您采用了proguard路线,则需要重新评估依赖关系,并对使用反射的任何代码进行特殊例外处理。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.