I have this error.
Error: execution completed for task ': myApp: createDebugMainDexClassList'. com.android.ide.common.internal.LoggedErrorException: The command failed to run: java -Xmx1024M -cp \ android-sdk \ build-tools \ 19.1.0 \ lib \ dx.jar com.android.multidex.ClassReferenceListBuilder myApp \ build \ intermediates \ multi-dex \ debug \ componentClasses.jar myApp \ build \ intermediates \ multi-dex \ Debug \ allclasses.jar
Error code: 1 Output: Error: could not find or load the main class com.android.multidex.ClassReferenceListBuilder
I am trying to use the multidex library because my application followed the method 65000, because I use external libraries, as the Link describes, I have added lines in the mainfest and build.gradle file, any tips will be appreciated. thanks
EDIT after several starts I got this error.
Error: execution completed for task ': myApp: dexDebug'. com.android.ide.common.internal.LoggedErrorException: Failed to run the command: \ android-sdk \ build-tools \ 21.1.0 \ dx.bat --dex --no-optimize --multi-dex --main- dex-list myApp \ build \ intermediates \ multi-dex \ debug \ maindexlist. txt --output myApp \ build \ intermediates \ dex \ debug --input-list = myApp \ build \ intermediates \ tmp \ dex \ debug \ inputList.txt, Error code: 3.
Conclusion: UNEXPECTED TOP LEVEL ERROR: java.lang.OutOfMemoryError: Java heap space
I tried to increase the size of Xms1024m -Xmx1024m, which is located in the file 'studio64.exe.vmoptions', but it still does not help, I also tried in Settings> Compiler> Xms1024m VM -Xmx1024m VM Settings
source share