Vansuita Jr. Vansuita Jr. - 24 days ago 17
Android Question

Multiple dex files define Lcom/google/android/gms/internal/zzrx;

I'm creating an Shopify Android App using their api. My app also use Google firebase to do the sign-ins. this is my dependencies.

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:24.1.1'
compile 'com.shopify.mobilebuysdk:buy:2.0.2'
compile 'com.google.firebase:firebase-auth:9.6.1'
compile 'com.google.android.gms:play-services-auth:9.6.1'
}


When I try to build the app I'm getting this error:

Error:Execution failed for task ':app:transformClassesWithDexForDebug'.


com.android.build.api.transform.TransformException: com.android.ide.common.process.ProcessException: java.util.concurrent.ExecutionException: com.android.dex.DexException: Multiple dex files define Lcom/google/android/gms/internal/zzrx;


I tried to add this on my build.gradle(app):

defaultConfig {
multiDexEnabled true
}


So then a got this:

Error:Execution failed for task ':app:transformClassesWithJarMergingForDebug'.


com.android.build.api.transform.TransformException: java.util.zip.ZipException: duplicate entry: com/google/android/gms/internal/zzrx.class


What can I do to use both libraries in the same project?

Answer

Solved

I Just solved my problem with this lines:

configurations {
    all*.exclude group: 'com.google.android.gms', module: 'play-services-wallet'
}
Comments