一个Android工程依赖了一个有 AndroidManifest.xml出现的错误

来源:互联网 发布:java技术的web服务器 编辑:程序博客网 时间:2024/06/05 16:44

出现的错误如下:

Error:Execution failed for task ':app:processDebugManifest'.
> Manifest merger failed : Attribute application@theme value=(@style/AppTheme) from AndroidManifest.xml:10:9-40
is also present at [Call:calllibrary:unspecified] AndroidManifest.xml:17:9-65 value=(@style/Theme.AppCompat.Light.NoActionBar).
Suggestion: add 'tools:replace="android:theme"' to <application> element at AndroidManifest.xml:5:5-18:19 to override.





解决办法:

在主项目的application节点添加

 tools:replace="android:icon",然后会提示导一句话
tagxmlns:tools="http://schemas.Android.com/tools"
,重新编译一下就可以了

位置如下:

<?xml version="1.0" encoding="utf-8"?><manifest xmlns:android="http://schemas.android.com/apk/res/android"    xmlns:tools="http://schemas.android.com/tools"    package="com.hzjiteng.call">    tagxmlns:tools="http://schemas.Android.com/tools"




0 0
原创粉丝点击