我正在構建一個android應用程序,並在我的應用程序中試圖導入一些東西。我成功地使用字體真棒並使用G帳戶登錄。但是,當它來到FireBase我有這樣的問題:這是什麼時候Gradle錯了?
Error:Error converting bytecode to dex: Cause: com.android.dex.DexException: Multiple dex files define Lcom/firebase/client/android/AndroidCredentialStore;
Error:Execution failed for task ':app:transformClassesWithDexForDebug'.
com.android.build.api.transform.TransformException: com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Program Files\Java\jdk1.8.0_73\bin\java.exe'' finished with non-zero exit value 2
這是gradle問題?
apply plugin: 'com.android.application'
apply plugin: 'com.google.gms.google-services'
android {
compileSdkVersion 23
buildToolsVersion "23.0.2"
defaultConfig {
applicationId "com.example.tiennguyenhoang.firebaseapp"
minSdkVersion 16
targetSdkVersion 23
versionCode 1
versionName "1.0"
multiDexEnabled = true
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions {
exclude 'META-INF/LICENSE'
exclude 'META-INF/LICENSE-FIREBASE.txt'
exclude 'META-INF/NOTICE'
}
}
顯示你的'build.gradle' –
'defaultConfig {multidexEnabled = true }' –
如何在這裏顯示代碼? –