Set up your project to run as a standalone Java application by specifying the core name space (i.e app.core) to be the main class invoked for the jar file by specifying it with :main. In addition, add a uberjar profile for AOT compilation.
project.clj:
(defproject app "1.0.0-SNAPSHOT"
:description "app Example."
:dependencies
[[org.clojure/clojure "1.8.0"]]
:profiles {:uberjar {:aot :all}}
:main app.core)
Ensure you have :gen-class specified in the name-space of your program. Also define a -main function to act as the main entry point.
src/app/core.clj:
(ns app.core
(:gen-class))
(defn -main [& args]
(dostuff ""))
Then use Packr (https://github.com/libgdx/packr), a small application for packaging up a JAR, assets and a JVM for distribution on Windows, Linux and Mac OS X.
Create a Packr configuration file.
config.json
{
"platform": "mac",
"jdk": "/Library/Java/JavaVirtualMachines/jdk1.8.0_65.jdk/Contents/Home/",
"executable": "My App",
"classpath": [
"target/app-1.0.0-SNAPSHOT-standalone.jar"
],
"mainclass": "app.core",
"icon": "resources/icon.icns",
"minimizejre": "soft",
"output": "myapp.app"
}
then run
$ lein uberjar
$ java -jar packr.jar config.json
You will now have a package that can be distributed as native app. This process works well for GUI apps. Sorry i know nothing about Vala.