Instead of this
packagingOptions {
exclude 'META-INF/LICENSE'
exclude 'META-INF/NOTICE'
}
try this
packagingOptions {
exclude 'META-INF/DEPENDENCIES.txt'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/notice.txt'
exclude 'META-INF/license.txt'
exclude 'META-INF/dependencies.txt'
exclude 'META-INF/LGPL2.1'
}
and more thing
Remove this line
apply plugin: 'com.google.gms.google-services'
from Bottom and add to Top after this apply plugin: 'com.android.application'
.
apply plugin: 'com.android.application'
apply plugin: 'com.google.gms.google-services'
Update :
just remove
compile fileTree(dir: 'libs', include: '*.jar')
and apply dependencies.