Error:Execution failed for task ':app:processDebugManifest'.
2017-03-07 17:16
483 查看
遇到这个报错的时候,不要慌
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
这个报错肯定是你导报依赖出的问题,我看很多人的解决方案都是复制复制,烦死我了,搞了我一晚上都没搞好
我现在来说,真正的搞定方案第一步:
原因:
AS的Gradle插件默认会启用Manifest Merger Tool,若Library项目中也定义了与主项目相同的属性(例如默认生成的Android:icon和android:theme),则此时会合并失败,并报上面的错误。
解决方法有以下2种:
方法1:在Manifest.xml的application标签下添加tools:replace="android:icon, android:theme"(多个属性用,隔开,并且记住在manifest根标签上加入xmlns:tools="http://schemas.android.com/tools",否则会找不到namespace哦)
方法2:在build.gradle根标签上加上useOldManifestMerger true (懒人方法)
像sweet-alert-dialog 这个第三方库。
sweet-alert-dialog是一个带动画效果的自定义对话框样式,可以让你的Android程序的对话框优美很多。GitHub地址
## Android Studio中引用
repositories
{
mavenCentral()
}
dependencies
{ compile
'cn.pedant.sweetalert:library:1.3'}
引用之后,就会报上面的错误。
在这里,按照步骤来
在manifest标签中加入:
xmlns:tools="http://schemas.android.com/tools"
在application中加入
tools:replace="icon"
重新Make Project,问题解决~
Error:Execution
failed for task ':app:processDebugManifest'.
> Manifest merger failed with multiple errors, see logs
或者
Error:(26, 9) Attribute application@icon value=(@drawable/logo) from AndroidManifest.xml:26:9Error:(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
这个报错肯定是你导报依赖出的问题,我看很多人的解决方案都是复制复制,烦死我了,搞了我一晚上都没搞好
我现在来说,真正的搞定方案第一步:
原因:
AS的Gradle插件默认会启用Manifest Merger Tool,若Library项目中也定义了与主项目相同的属性(例如默认生成的Android:icon和android:theme),则此时会合并失败,并报上面的错误。
解决方法有以下2种:
方法1:在Manifest.xml的application标签下添加tools:replace="android:icon, android:theme"(多个属性用,隔开,并且记住在manifest根标签上加入xmlns:tools="http://schemas.android.com/tools",否则会找不到namespace哦)
方法2:在build.gradle根标签上加上useOldManifestMerger true (懒人方法)
像sweet-alert-dialog 这个第三方库。
sweet-alert-dialog是一个带动画效果的自定义对话框样式,可以让你的Android程序的对话框优美很多。GitHub地址
## Android Studio中引用
repositories
{
mavenCentral()
}
dependencies
{ compile
'cn.pedant.sweetalert:library:1.3'}
引用之后,就会报上面的错误。
在这里,按照步骤来
在manifest标签中加入:
xmlns:tools="http://schemas.android.com/tools"
在application中加入
tools:replace="icon"
重新Make Project,问题解决~
相关文章推荐
- 关于Android Studio 报Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger fa
- 安卓异常之Error:Execution failed for task ':app:processDebugManifest'
- android studio导入项目出错:Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger
- Error:Execution failed for task ':app:processDebugManifest'.
- 终极报错解决方案:Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed with
- Error:Execution failed for task ':app:processDebugManifest'.
- Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed with multiple
- Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed with multiple
- Error:Execution failed for task ':app:processDebugManifest'. Manifest merger failed with 问题解决方案
- 十、Error:Execution failed for task ':app:processDebugManifest'.
- Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed with multiple
- android 遇到Error:Execution failed for task ':app:processDebugManifest'. > 解决
- Error:Execution failed for task ':app:processDebugManifest'
- android异常Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed with
- Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed with multiple
- Android Studio集成Sweet Alert Dialog报错(Error:Execution failed for task ':app:processDebugManifest'.)
- AS导入项目出现Error:Execution failed for task ':app:processDebugManifest'.错误
- 终极报错解决方案:Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed with
- Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed with multiple
- Error:Execution failed for task ':app:processDebugManifest'.