Error - java.lang.OutOfMemoryError: Java heap space

CodeMonkeyCodeMonkey GBMember ✭✭✭

Hi all

I am trying to get Maps V2 working in my app, after many hours I have managed to rebuild the binding project with help from @Cheesebaron, I added the dll to my project and I am now getting this error when I try build:

/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Common.targets: Error: Tool exited with code: 3. Output: 
UNEXPECTED TOP-LEVEL ERROR:
java.lang.OutOfMemoryError: Java heap space
    at com.android.dx.rop.code.RegisterSpecSet.<init>(RegisterSpecSet.java:49)
    at com.android.dx.rop.code.RegisterSpecSet.mutableCopy(RegisterSpecSet.java:383)
    at com.android.dx.ssa.LocalVariableInfo.mergeStarts(LocalVariableInfo.java:118)
    at com.android.dx.ssa.LocalVariableExtractor.processBlock(LocalVariableExtractor.java:203)
    at com.android.dx.ssa.LocalVariableExtractor.doit(LocalVariableExtractor.java:90)
    at com.android.dx.ssa.LocalVariableExtractor.extract(LocalVariableExtractor.java:56)
    at com.android.dx.ssa.SsaConverter.convertToSsaMethod(SsaConverter.java:50)
    at com.android.dx.ssa.Optimizer.optimize(Optimizer.java:99)
    at com.android.dx.ssa.Optimizer.optimize(Optimizer.java:73)
    at com.android.dx.dex.cf.CfTranslator.processMethods(CfTranslator.java:273)
    at com.android.dx.dex.cf.CfTranslator.translate0(CfTranslator.java:134)
    at com.android.dx.dex.cf.CfTranslator.translate(CfTranslator.java:87)
    at com.android.dx.command.dexer.Main.processClass(Main.java:487)
    at com.android.dx.command.dexer.Main.processFileBytes(Main.java:459)
    at com.android.dx.command.dexer.Main.access$400(Main.java:67)
    at com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:398)
    at com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:245)
    at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:131)
    at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:109)
    at com.android.dx.command.dexer.Main.processOne(Main.java:422)
    at com.android.dx.command.dexer.Main.processAllFiles(Main.java:333)
    at com.android.dx.command.dexer.Main.run(Main.java:209)
    at com.android.dx.command.dexer.Main.main(Main.java:174)
    at com.android.dx.command.Main.main(Main.java:91)
 (ClubMarketingAndroid)

I found a thread on stackoverflow about this issue but don't know how to apply this fix in osx?

http://stackoverflow.com/questions/13523257/how-to-fix-outofmemoryerror-java-heap-space-while-compiling-monodroid-app-in

Adrian

Posts

Sign In or Register to comment.