您的位置:首页 > 移动开发 > Android开发

Androidstudio常见错误"Manifest merger failed with multiple errors, see logs"

2017-07-12 09:07 573 查看
问题:

Error:Execution failed for task ':xxxr:processDebugManifest'.

> Manifest merger failed withmultiple errors, see logs

原因:

AS的Gradle插件默认会启用Manifest Merger Tool,若Library项目中也定义了与主项目相同的属性(例如默认生成的Android:icon和Android:theme),则此时会合并失败,并报上面的错误。

解决办法:

在manifest根标签上加入xmlns:tools="http://schemas.android.com/tools",

并在Manifest.xml的application标签下添加tools:replace="icon,label,theme,name"(多个属性用,隔开,视情况而定,最好照抄)。

把appliction的所有都写进去,不然还是报这个错误,

不能写成tools:replace="android:icon, android:label, android:theme",这样不会报错,但也不能解决错误。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐