android编译错误AAPT: error: resource android:attr/lStar not found
android编译错误AAPT: error: resource android:attr/lStar not found老项目编译出现AAPT: error: resource android:attr/lStar not found字样错误提示,是因为第三方依赖包依赖需求不明确,导致直接下载最新版依赖不匹配导致。全文搜索androidx.core:core字样(注意ignore文件过滤设置),
·
android编译错误AAPT: error: resource android:attr/lStar not found
老项目编译出现AAPT: error: resource android:attr/lStar not found字样错误提示,是因为第三方依赖包依赖需求不明确,导致直接下载最新版依赖不匹配导致。
全文搜索androidx.core:core字样(注意ignore文件过滤设置),找到关键字后,一般会有两个可能:
1、androidx.core:core-ktx…
2、androidx.core:core…
如果搜索关键字是依赖配置,则直接修改依赖版本号:
例:androidx.core:core-ktx:+ 改为 androidx.core:core-ktx:1.6.0
如果不在配置内,则设置强制版本
在app/build.gradle中的dependencies上面添加以下代码:
configurations.all {
resolutionStrategy {
force 'androidx.core:core:1.6.0' //两个依赖根据搜索出的关键字选择
force 'androidx.core:core-ktx:1.6.0'
}
}
更多推荐
已为社区贡献1条内容
所有评论(0)