Android Studio Manifest merger failed with multiple errors

Viewed 4781

I have the following error:

Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed with multiple errors, see logs

AndroidManifest.xml

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.google.android.gms.samples.vision.face.facetracker">

<uses-feature android:name="android.hardware.camera" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />

<uses-permission android:name="android.permission.INTERNET" />

<application
    android:allowBackup="true"
    android:icon="@drawable/icon"
    android:theme="@style/Theme.AppCompat"
    android:label="FaceTracker">
    <activity        
android:name="com.google.android.gms.samples.vision.
face.facetracker.FaceTrackerActivity"
        android:icon="@drawable/icon"
        android:label="Face Tracker"
        android:theme="@style/Theme.AppCompat.NoActionBar"
        android:screenOrientation="fullSensor">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />

            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
</application>
</manifest>

and for build.gradle as follows

apply plugin: 'com.android.application'
android {
   compileSdkVersion 25
buildToolsVersion '26'
defaultConfig {
    applicationId "com.google.android.gms.samples.vision.face.facetracker"
    minSdkVersion 9
    targetSdkVersion 25
    versionCode 1
    versionName "1.0"
}
buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'),       
'proguard-rules.pro'
    }
}}
dependencies {
compile fileTree(include: ['*.jar'],dir: 'libs')
compile 'com.android.support:appcompat-v7:25.1.0'
compile 'com.android.support:design:25.2.0'
compile 'com.google.android.gms:play-services-vision:9.4.0+'
compile 'com.squareup.okhttp:okhttp:2.5.0'
compile 'com.empatica.empalink:empalink:2.1@aar'}

I have tried other solutions provided here on stack overflow but none worked. Thanks a lot

3 Answers

I had the same problem, and the error occurred because of the Bottom line change:

    android:supportsRtl="false"

The error was fixed when I changed "false" to "true":

    android:supportsRtl="true"

In my opinion, this error returns to your last change in the manifest, see the last Time what you changed. I hope to work for you. I also have another offer, you can refer to page "merged Manifest" in your AndroidManifest.xml and see your own error

Anything repeated within one manifest file example Activity, Service declaration can cause this issue.

Related