在我的项目中,只要我使用更多库,我必须使用tools:replace
覆盖某些功能,例如supportsRtl
,当我添加工具名称空间并使用tools:replace="android:supportsRtl,android:allowBackup"
时应用程序标签我收到此错误:
Error:Execution failed for task ':app:processDebugManifest'.
> Manifest merger failed with multiple errors, see logs
清单内容:
<?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.myapp.androidapp">
<uses-permission android:name="android.permission.INTERNET"/>
<application
android:name=".APP"
android:allowBackup="false"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:largeHeap="true"
android:roundIcon="@mipmap/ic_launcher_round"
android:theme="@style/AppTheme"
tools:replace="android:supportsRtl,android:allowBackup">
<activity android:name=".Ui.ActivityStartUpApplication">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
<activity
android:name=".Ui.ApplicationRobot.view.ActivityRegisterRobot"
android:configChanges="screenSize|orientation"/>
<activity
android:name=".Ui.ActivityChannelContent.view.ActivityChannelContent"
android:configChanges="screenSize|orientation">
</activity>
<activity
android:name=".Ui.ActivityMain.view.ActivityMain"
android:configChanges="screenSize|orientation"/>
</application>
</manifest>
答案 0 :(得分:0)
通过添加
解决了问题android:supportsRtl="false"
之前
tools:replace="android:supportsRtl,android:allowBackup"