Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android problem: DexException: Multiple dex files... #11

Closed
beeant opened this issue Jul 3, 2016 · 12 comments
Closed

Android problem: DexException: Multiple dex files... #11

beeant opened this issue Jul 3, 2016 · 12 comments

Comments

@beeant
Copy link

beeant commented Jul 3, 2016

Hello,

Thank you for this module.
I have successfully setup on the iOS, but I keep on getting this error while compiling for android.

Unknown source file : com.android.dex.DexException: Multiple dex files define Lcom/google/android/gms/iid/MessengerCompat$1;
@dcworldwide
Copy link

See bamlab/react-native-image-resizer#15. This project had a similar issue and a fix was suggested. @beeant please confirm if it works for you.

@sibelius
Copy link

I'm having the same issue using this lib with https://github.com/zo0r/react-native-push-notification

I think both libs depends on google play services is the reason to cause this problem

@rturk
Copy link

rturk commented Jul 17, 2016

I'm having the same issue with RN29. I have no idea how to fix this

@evollu
Copy link
Owner

evollu commented Jul 17, 2016

have you tried cleaning the build?

@sibelius
Copy link

as react-native-push-notification and maybe other packages depends on google play services we need match the google play services in this packages

you can run

./gradlew -q app:dependencies

to discover which packages depends on google play services, and which version they r using

them u can force them to use a specific version

dependencies {
   compile ('com.google.android.gms:play-services-gcm:9.2.0') {
        force = true; 
   } 
}

@evollu
Copy link
Owner

evollu commented Jul 18, 2016

@sibelius can you specify which file needs that change?
also react-native-push-notification relies on gms 8.+, could that be an issue?

@sibelius
Copy link

u should change android/app/build.gradle

and react-native-push-notification relies on gms 8.+ but u can force another version as above

@evollu
Copy link
Owner

evollu commented Jul 18, 2016

cool @beeant @rturk does this solve your issue?

@rturk
Copy link

rturk commented Jul 20, 2016

@evollu after much work I've managed to make my app work. Thanks.
Looks like latest rnpm link still a little bugged and is not correctly importing packages.

@evollu
Copy link
Owner

evollu commented Jul 21, 2016

cool.

@evollu evollu closed this as completed Jul 21, 2016
@afilp
Copy link

afilp commented Jun 1, 2017

@evollu Hello, I have a similar conflict with "react-native-intercom" but I am not sure what needs to be done there. Should I do something there? Or here?

@evollu
Copy link
Owner

evollu commented Jun 1, 2017

https://medium.com/@suchydan/how-to-solve-google-play-services-version-collision-in-gradle-dependencies-ef086ae5c75f#.9l0u84y9t

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants