From: Sascha H. <sa...@xm...> - 2011-03-09 10:45:15
|
Specifying at least -Xmx1G has been proven useful in the past. On Wed, Mar 9, 2011 at 11:42 AM, Ian Frisbie <ifr...@gm...> wrote: > I don't specify the starting memory size, just the max - try doing that. > Here is an example of a shell file I use to launch: > > #!/bin/sh > alias xmlvm="java -Xmx500M -jar [full path to xmlvm]/dist/xmlvm.jar" > xmlvm --in=[files] --target=objc --out=[target directory] > > You also might want to start by specifying a single class file, just as a > test. I'm guessing it has something to do with specifying starting mem > though ("-Xms32m") > > Ian > > On Wed, Mar 9, 2011 at 3:55 AM, Christoffer Kristensen < > chr...@ya...> wrote: > >> Hi. >> I'm trying to convert a client/server android app to iphone with xmlvm. Up >> until now without luck. >> I'm on a Mac running a 64 bit version of snow loepard. >> When i follow the manual, provided by xmlvm, i keep getting problems. I'm >> new to both xmlvm as well as the terminal instructions. >> >> What I do is: >> >> *Compiling xmlvm: In terminal i change directory to xmlvm. type "ant" and >> xmlvm compiles and builds allright. >> >> *Invoking xmlvm: >> >> I type "java -jar dist/xmlvm.jar" >> >> What i get in return is: >> >> Exception in thread "main" java.lang.OutOfMemoryError: Java heap space >> at java.util.Arrays.copyOf(Arrays.java:2786) >> at >> java.io.ByteArrayOutputStream.toByteArray(ByteArrayOutputStream.java:133) >> at >> com.simontuffs.onejar.JarClassLoader.alreadyCached(JarClassLoader.java:796) >> at com.simontuffs.onejar.JarClassLoader.loadBytes(JarClassLoader.java:509) >> at >> com.simontuffs.onejar.JarClassLoader.loadByteCode(JarClassLoader.java:455) >> at >> com.simontuffs.onejar.JarClassLoader.loadByteCode(JarClassLoader.java:446) >> at com.simontuffs.onejar.JarClassLoader.load(JarClassLoader.java:386) >> at com.simontuffs.onejar.JarClassLoader.load(JarClassLoader.java:276) >> at com.simontuffs.onejar.Boot.run(Boot.java:282) >> at com.simontuffs.onejar.Boot.main(Boot.java:159) >> >> *In order to change the Java heap Space i run the command "java -Xms32m >> -Xmx512m -jar dist/xmlvm.jar" >> What i get in return is: >> >> Error: Need at least one --in argument Usage: xmlvm [--in=<path> >> [--out=<dir>]] >> [--target=[xmlvm|dexmlvm|jvm|clr|dfa|class|exe|dex|js|java|c|python|objc|iphone|qooxdoo|vtable|webos]] >> [--skeleton=<type>] [--lib=<name> [--app-name=<app-name>] >> [--resource=<path>] [--qx-main=<main-class> [--qx-debug]] >> [--debug=[none|error|warning|all]] [--version] [--help] Give --help >> parameter to see more detailed command line instructions. >> >> NB. i'm still in the xmlvm directory as i was from the start. >> >> *Next i would create an alias by typing >> "alias xmlvm="java -jar $(pwd)/dist/xmlvm.jar" >> >> i don't know if the alias is created or not. >> >> *Next i would define my in path by typing "xmlvm --in=<in here i would >> type the path to my android app from root>" >> >> When i do this I get >> Exception in thread "main" java.lang.OutOfMemoryError: Java heap space >> at java.util.Arrays.copyOf(Arrays.java:2786) >> at >> java.io.ByteArrayOutputStream.toByteArray(ByteArrayOutputStream.java:133) >> at >> com.simontuffs.onejar.JarClassLoader.alreadyCached(JarClassLoader.java:796) >> at com.simontuffs.onejar.JarClassLoader.loadBytes(JarClassLoader.java:509) >> at >> com.simontuffs.onejar.JarClassLoader.loadByteCode(JarClassLoader.java:455) >> at >> com.simontuffs.onejar.JarClassLoader.loadByteCode(JarClassLoader.java:446) >> at com.simontuffs.onejar.JarClassLoader.load(JarClassLoader.java:386) >> at com.simontuffs.onejar.JarClassLoader.load(JarClassLoader.java:276) >> at com.simontuffs.onejar.Boot.run(Boot.java:282) >> at com.simontuffs.onejar.Boot.main(Boot.java:159) >> >> *Then i would define the target and the app name and the output: >> --target=android-on-iphone >> --iphone-app=TheApplication --out= >> >> I never got this far. my problems started when trying to invoke xmlvm. >> I'm not sure what directory i need to be in when typing the different >> commands. And i'm not sure where my Android app needs to be placed, in order >> for the xmlvm to get a hold of it. >> What am i doing wrong? I hope you can help me! >> Thank you for introducing this great project I hope that i'll get my head >> around it someday. >> >> Best regards >> Christoffer Kristensen >> >> >> >> >> >> ------------------------------------------------------------------------------ >> Colocation vs. Managed Hosting >> A question and answer guide to determining the best fit >> for your organization - today and in the future. >> http://p.sf.net/sfu/internap-sfd2d >> _______________________________________________ >> xmlvm-users mailing list >> xml...@li... >> https://lists.sourceforge.net/lists/listinfo/xmlvm-users >> >> > > > -- > Ian D. Frisbie > > > > ------------------------------------------------------------------------------ > Colocation vs. Managed Hosting > A question and answer guide to determining the best fit > for your organization - today and in the future. > http://p.sf.net/sfu/internap-sfd2d > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > > |