Error:Execution failed for task ':XXXX:processDebugManifest'. > Manifest merger failed with multiple

来源:互联网 发布:java开发大学项目 编辑:程序博客网 时间:2024/06/05 06:50

Error:(26, 9) Attribute application@icon value=(@drawable/logo) from AndroidManifest.xml:26:9

Error:(28, 9) Attribute application@theme value=(@style/ThemeActionBar) from AndroidManifest.xml:28:9
is also present at XXXX-trunk:XXXXLib:unspecified:15:9 value=(@style/AppTheme)

Suggestion: add 'tools:replace="android:theme"' to <application> element at AndroidManifest.xml:24:5 to override

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

> Manifest merger failed with multiple errors, see logs

如果出现以上的错误 是因为你的Libary中与主项目有了相同的属性 然后合并失败

解决方法

在Manifest.xml的application标签下添加tools:replace="android:icon, android:theme"(多个属性用,隔开,并且记住在manifest根标签上加入xmlns:tools="http://schemas.android.com/tools")


1 0
原创粉丝点击