0

This is as intelligently as I can ask this question right now. I am trying to compile my code and get the following error:

Unable to execute dex: Cannot merge new index 67124 into a non-jumbo instruction!
 Conversion to Dalvik format failed: Unable to execute dex: Cannot merge new index 67124 into a non-jumbo instruction!

It started happening after I integrated PayPal sdk for payment. I see the error at my first attempt to test.

I already tried:

dex.force.jumbo=true
user3093402
  • 1,419
  • 4
  • 20
  • 28
  • I am having a similar issue (don't have the PayPal SDK integrated though). Weird thing is, exporing and running the .apk works. Just running it from Eclipse does not. :-/ – Daniel Jan 30 '14 at 20:25
  • I had similar issue, but cleaning project worked for me. – LostGeek Jun 12 '14 at 08:52
  • Solution can be found here : http://stackoverflow.com/questions/17970957/cannot-compile-unable-to-execute-dex-cannot-merge-non-jumbo-instruction – Ahmed Adel Ismail Jul 07 '14 at 16:04

2 Answers2

1

I got the same error and I was able to build after several steps. Here they are. Basically, your project is way too big for eclipse/android to handle so you have to A) increase the memory sizes and B) reduce the number of methods you have.

  1. Increase Heap Size in eclipse.ini file.

How to find eclipse.ini file.

How do I increase the size of heap by editing eclipse.ini

I used the following values: -Xms2048m -Xmx2048m

  1. That didn't really solve the problem so I followed the instructions in this link. Specifically:

Add the following

dex.force.jumbo=true

in the first line of project.properties

  1. I then got this error: Unable to execute dex: method ID not in [0, 0xffff]: 65536 Which led me to another stack overflow answer here. I ended up deleting some .jars I didn't use anymore to reduce the number of methods my app uses.

I hope that helps!

Community
  • 1
  • 1
mogile_oli
  • 2,148
  • 2
  • 21
  • 21
0

I had similar error while compiling one of my android project in eclipse. I played around all the settings and finally changing eclipse heap memory in eclipse.ini file had succeed.

Try to give as much as memory as possible to eclipse if you have enough RAM. My settings in eclipse.ini file as follows, -Xms3g -Xmx3g -XX:MaxPermSize=3g

Let me know whether this works for you!

karthikk
  • 96
  • 5