Reputation: 89
i am creating a chat based app in this app its require AuthUI i used
compile 'com.firebaseui:firebase-ui-auth:0.4.0'
when i clicked on sync its show me this error
Error:Execution failed for task ':app:processDebugManifest'. Manifest merger failed : uses-sdk:minSdkVersion 15 cannot be smaller than version 16 declared in library [com.firebaseui:firebase-ui-auth:0.4.0] C:\Users\Pankaj.android\build-cache\b6b125d590bd1b7420872b94c0da26aebbc55221\output\AndroidManifest.xml Suggestion: use tools:overrideLibrary="com.firebase.ui.auth" to force usage
build.gradle(app)
compile 'com.android.support:appcompat-v7:26.+'
compile 'com.github.d-max:spots-dialog:0.7@aar'
compile 'com.squareup.picasso:picasso:2.5.2'
compile 'com.android.support:design:26.+'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
compile 'com.android.volley:volley:1.1.0'
compile 'com.github.bumptech.glide:glide:4.0.0'
compile 'com.android.support:recyclerview-v7:26.+'
compile 'net.gotev:uploadservice:2.1'
compile 'com.firebaseui:firebase-ui-database:0.4.0'
compile 'com.firebaseui:firebase-ui-auth:0.4.0'
compile 'com.android.support:support-v4:26.+'
testCompile 'junit:junit:4.12'
build.gradle(project)
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.3.0'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
classpath 'com.google.gms:google-services:3.1.0'
}
}
allprojects {
repositories {
jcenter()
maven {
url 'https://maven.fabric.io/public'
}
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
Upvotes: 0
Views: 578
Reputation: 76569
raise the minimum API level from 15
to 16
in the module's build.gradle
.
android {
defaultConfig {
minSdkVersion 16
}
}
tools:overrideLibrary
is not really an option, because it will crash on devices with API level 15
.
Upvotes: 3
Reputation: 17824
This is because FirebaseUI requires API 16 or above to run, while your app's minSdkVersion
is set at 15. If Android Studio let you build like this, your app would just crash for users on API 15.
The comments suggest using the tools:overrideLibrary
Manifest field, but I don't recommend doing this, because of the reasons described above. You'd have to implement your own authorization UI for API 15 users.
According to Google, 0.3% of active Android users are currently using API 15. This is only devices with the Play Store installed, but it's a pretty good representation of the total portion of Android users running API 15. If you're implementing FirebaseUI, it simply isn't worth it to make your own Auth UI for 0.3% of the total number of Android users.
The easiest and most sensible solution would probably be to just change your minSdkVersion
to 16. You're already missing out on the other 0.3% of users on API 10-14. Another 0.3% is nothing.
Upvotes: 2