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

Dx trouble writing output: already prepared... - Error in console #35

Closed
vedtam opened this issue Jun 18, 2015 · 11 comments
Closed

Dx trouble writing output: already prepared... - Error in console #35

vedtam opened this issue Jun 18, 2015 · 11 comments

Comments

@vedtam
Copy link

vedtam commented Jun 18, 2015

Hi,

  • braintree-api-1.6.1-full.jar
  • android:minSdkVersion="14"
  • android:targetSdkVersion="18"

I need to implement braintree inside my android app which has no issues, but as I copy the braintree jar file, into my projects libs folder and import the necessary classes, my app crashes.

Full error message in console:

Dx trouble writing output: already prepared
[2015-06-18 15:31:42 - Dex Loader] Unable to execute dex: Multiple dex files define Landroid/support/annotation/AnimRes;
[2015-06-18 15:31:42 - foto.studio] Conversion to Dalvik format failed: Unable to execute dex: Multiple dex files define Landroid/support/annotation/AnimRes;

I have removed, re imported everything twice, updated Eclipse packages too the latest version, and cleaned my project. But still got this issue. As I remove the braintree library my app returns to normal.

Please advice me what to do.
Thanks!

@punit006
Copy link

I am facing the same issue. I tried everything but of no use. And there is no proper documentation of how to integrate the Braintree library in android application for developers using eclipse.

@vedtam
Copy link
Author

vedtam commented Jun 18, 2015

I am googling for about 4 hours, but there is nothing related to this. Are you trying to set up the SDK manually like me? Have you tried using Maven?

@lkorth
Copy link
Member

lkorth commented Jun 18, 2015

This is only an issue in 1.6.1 and 1.6.0 with the full jar. A new optional dependency was added in these versions and the full jar picks it up and compiles it in. For now you can use 1.5.1 and we will look into not compiling Google Play Services into the full jar.

@vedtam
Copy link
Author

vedtam commented Jun 18, 2015

Hi,

Thanks, I try with this version, could you please tell me where could I find it? On gitHub I see only the latest version.

Regrads,
E.

On 18 Jun 2015, at 17:34, Luke Korth notifications@github.com wrote:

1.5.1

@lkorth
Copy link
Member

lkorth commented Jun 18, 2015

They're all on maven central

@vedtam
Copy link
Author

vedtam commented Jun 18, 2015

Hi,

Thanks, now my app compiles and runs ok!

Regards!
E.

On 18 Jun 2015, at 17:47, Luke Korth notifications@github.com wrote:

They're all on maven central http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22com.braintreepayments.api%22%20AND%20a%3A%22braintree-api%22

Reply to this email directly or view it on GitHub #35 (comment).

@lkorth lkorth closed this as completed Jun 20, 2015
@rambabupittala
Copy link

can any body post the code for android eclipse to integrate brainree payment ,i tried with website code but it is not working,please help me

@vedtam
Copy link
Author

vedtam commented Jul 22, 2015

You have to move your project to Android Studio, everything is much simpler in it like integrating Braintree, or any other library using gradle.

@lkorth
Copy link
Member

lkorth commented Jul 22, 2015

@rambabupittala if you start at the manual download documentation and follow them from there down it should be very straight forward how to add the library and integrate with it.

@rambabugithub
Copy link

Hi
thanks for reply ,i followed manually setup steps, but i struck at the Drop-in UI using Maven. i didn't getting to use drop-in using Maven ,cloud you help me to use Maven for drop in.

i followed this url :"http://stackoverflow.com/questions/8620127/maven-in-eclipse-step-by-step-installation"

@lkorth
Copy link
Member

lkorth commented Jul 22, 2015

The manual setup setups are only required if you are not using Maven. If you are using Maven there is no need to download the jar, you should just include the dependency in your pom.xml.

As far as how to use Maven with Eclipse, that's not something we can support.

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

5 participants