Android Error in Eclipse: "Unable to execute dex: Cannot merge new index 65799 into a non-jumbo instruction!"
Solution 1
One solution that I found that got it working for me was to add dex.force.jumbo=true
to my project.properties
.
This was pointed out at: https://groups.google.com/forum/?fromgroups=#!topic/adt-dev/tuLXN9GkVas
This is assuming you are running ADT 21 as this feature wasn't available in previous versions.
Solution 2
The same problem...just put
dex.force.jumbo=true
in the first line of project.properties
Solution 3
If using gradle build, just add the dexOptions into build.gradle to enable jumbo mode:
android {
dexOptions {
jumboMode = true
}
}
Remember to run "gradle clean" before your new building.
Solution 4
I had the same problem, but my IDE was IntelliJ IDEA 13. In that version, the dex.force.jumbo
instruction in the project.properties
file is ignored.
To enable it, just go to Settings | Compiler | Android DX and select the Force jumbo mode option.
Hope it helps (this is the only SO-related question I have been able to find).
Solution 5
Just adding jumboMode=true
didn't work for my gradle build. However this worked (quoted from Xavier in the adt-dev group as a reply to a bug filed in this area):
"Try to delete all the build folders manually and build again, making sure the dexOptions.jumboMode is set to true in the project?
There's an issue where the root project's build is not deleted in the clean task and this contains some information about the pre-dexed libraries."
Related videos on Youtube
Ripul
Updated on March 21, 2020Comments
-
Ripul over 4 years
I am trying an Android project using OpenSAML using Eclipse. I have added all the required jar files in the build path. Now, when I run the program as an Android Application the following error shows up:
[2012-11-18 11:52:59 - Dex Loader] Unable to execute dex: Cannot merge new index 67075 into a non-jumbo instruction! [2012-11-18 11:52:59 - MyTestProgram] Conversion to Dalvik format failed: Unable to execute dex: Cannot merge new index 67075 into a non-jumbo instruction!
I googled a bit, but nothing came up. What could this error mean?
-
MysticMagicϡ over 11 yearsTry reopening your eclipse. I was able to solve that error using that.
-
Ripul over 11 yearsI tried that so many times, but just stuck here!
-
Mightian about 8 years@Ripul were you able to get opensaml and android poc working
-
Ripul about 8 years@war_Hero, not really, it had far too much dependencies which I could not bundle in one single Android app. I wrote down a curtailed version of SAML, based on SICS lightweight SAML library (sics.se/~ludwig/assertionServer/SAMLlib.pdf). Hope it helps.
-
Mightian about 8 years@Ripul am trying to implement saml in android webview so far nothing has come up yet, asked cause you had tagged both android and saml thanks anyways
-
-
Ripul over 11 yearsThanks for your answer. I tried that one. But I get this:<br/>Installation error: INSTALL_FAILED_DEXOPT Please check logcat output for more details. Launch canceled!</br> Then I checked the logcat. And in the logcat, the output is: </br>W/installd(40): DexInv: --- END '/data/app/*.apk' --- status=0xff00, process failed E/installd(40): dexopt failed on '/data/dalvik-cache/data@app@*[email protected]' res = 65280 W/PackageManager(149): Package couldn't be installed in /data/app/*.apk. <br/> Any ideas?
-
Malachi over 11 yearsTried doing a clean rebuild?
-
Ripul over 11 yearsSure I did. The trouble is the logcat is not producing enough output to understand what is happening!
-
PJL over 11 yearsWorked for me, did need to clean and rebuild and then run into a problem due to INSTALL_FAILED_UID_CHANGED which a reboot of the phone seem to solve.
-
Ripul over 11 yearsI cleaned and rebuilt the project, rebooted the phone, restarted the Editor. Still no solution. Just stuck!
-
PJL over 11 yearsI also got stuck to the point where I had to delete my sources and get fresh ones from source control which fixed the problem. I do think that this problem is waiting to bite me again and my errors were flipping between
INSTALL_FAILED_UID_CHANGED
andINSTALL_FAILED_DEXOPT
. -
Hiren Patel about 11 yearsi put this dex.force.jumbo=true, but i couldn't solve my problem
-
Malachi about 11 years@HirenPatel what version of ADT are you running?
-
Hiren Patel about 11 yearshi, i tried this but i can not get proper result, please tell another solution for this problem, thanks in advance.
-
string.Empty about 11 yearsI added
dex.force.jumbo=true
to myproject.properties
and i have version 21 of ADT and i still get theUnable to execute dex: Cannot merge new index 66719 into a non-jumbo instruction!
error. -
Malachi about 11 years@NicolasTyler Tried doing a clean then build? You may have to close and open your project...
-
string.Empty about 11 yearsi tried increasing eclipses heap size and adding
dex.force.jumbo=true
but still get this error: pastebin.com/UMzK2Xvg -
Rohan over 9 years@Ripul i don't know whether you have solved this or not , may be its too late but if you haven't solved this make sure that line "dex.force.jumbo=true" is first line in your project.properties file.
-
ViliusK about 9 yearsNo such section Android DX in settings. And no such option Force jumbo mode in Android Studio (based on IntelliJ IDEA).
-
Sebastiano about 9 yearsBecause IntelliJ differs from Android Studio in many aspects, this being one of them. Since Studio uses Gradle by default, you need to specify
dexOptions { jumboMode = true }
in yourbuild.gradle
file. -
stdout over 8 yearsDid not make any difference for me to put the line to the beginning or end. Still not working.
-
Rino over 8 yearsUsing Eclipse or Android Studio? This link can help you developer.android.com/tools/building/multidex.html