Reputation: 13
I just add Firebase in my build.gradle and set it update. After synchronize error shown minsdk 11 cannot lower than 14 declare in libraries. my build.gradle dependencies is below. A suggestion show in Build Gradle message in Android Monitor that use tool:overrideLibrary="com.google.firebase.firebase_core" to force use.
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion '25.0.0'
defaultConfig {
applicationId "com.indiauthoritymarketing.instasave"
minSdkVersion 11
targetSdkVersion 23
versionCode 2
versionName "InstaSve 2.1"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
allprojects {
gradle.projectsEvaluated {
tasks.withType(JavaCompile) {
options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation"
}
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.parse.bolts:bolts-android:1.+'
compile 'com.parse:parse-android:1.+'
compile 'com.android.support:appcompat-v7:25.3.1'
compile 'com.android.support:design:25.3.1'
compile 'com.android.support:recyclerview-v7:25.3.1'
compile 'com.android.support:cardview-v7:25.3.1'
compile 'com.google.android.gms:play-services-ads:11.0.4'
compile 'com.mani:ThinDownloadManager:1.2.2'
compile 'net.rdrei.android.dirchooser:library:3.2@aar'
compile 'com.google.firebase:firebase-core:11.0.4'
compile 'com.google.firebase:firebase-auth:11.0.4'
compile 'com.google.firebase:firebase-messaging:11.0.4'
compile 'com.google.firebase:firebase-ads:11.0.4'
compile 'com.google.firebase:firebase-appindexing:11.0.4'
testCompile 'junit:junit:4.12'
compile 'com.android.support:support-annotations:25.3.1'
}
apply plugin: 'com.google.gms.google-services'
And Build Dependencies is below :--
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.3.3'
classpath 'com.google.gms:google-services:3.1.0'
}
}
allprojects {
repositories {
jcenter()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
Where I missing.
Thanks in Advance.
Upvotes: 1
Views: 717
Reputation: 317467
On Android, Firebase is distributed as part of Play Services. Play Services now requires a minimum API level 14 to use it. So you have to target API level 14 at a minimum.
Upvotes: 1