Question

I am under the impression that Launch4J cannot create launchers for OS X. Correct me, if I am wrong.

I would like to use something similar so I can set the initial heap size/ max heap size for my Java application without using command line options (java -jar -Xmx1024m etc....).

Any recommendations?

Était-ce utile?

La solution

What you want is an Application Bundle. It include a properties file (Info.plist) where you can set things like Xmx, etc.

You can also use Oracle's appbundler tool to create an application bundle.

Another no-brainer option is to create a shell script. Something like this:

#!/bin/bash
java -jar myJar.jar

Autres conseils

Eclipse can export a run configuration as a runnable jar file or a Mac OSX application bundle. In the run configuration, add the command line options to the VM arguments textbox in the arguments tab.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top