I am trying to create a standalone .exe file (or something equivalent) from a scala project I have started. I need to create this in such a way thet the person using the application has to do the least amount of work possible (double-click an installer or just the .exe file). What are my options?
Asked
Active
Viewed 1.5k times
16
-
2They're identical to building a Java application. Depending on your OS and development environment you should be able to Google up a solution. – Donald.McLean Jul 03 '12 at 15:01
-
2Any reason you tagged this Scala and not Java? If you are using Scala, are you using sbt to build your project? If so, have you look at the [plugins](http://www.scala-sbt.org/plugins.html). There is `sbt-assembly` to create a double-clickable jar, and izpack to create an installer. Also [this question](http://stackoverflow.com/questions/1967549/java-packaging-tools-alternatives-for-jsmooth-launch4j-onejar) – 0__ Jul 03 '12 at 15:16
-
2Java 8 will also make it easier by enabling people to build "native" packages like exe, deb, rpm etc. – soc Jul 03 '12 at 15:41
-
As others have said, its no different to how you would do for Java. I like [JSmooth](http://jsmooth.sourceforge.net/) – aishwarya Jul 03 '12 at 19:52
-
You are trying to build _a stand-alone **scala** executable_ _from a **java** project_ ? Makes no sense for me. I guess you might be looking for a self executable jar. – user272735 Jul 04 '12 at 04:18
-
Sorry for the mess-up, I meant from a Scala project. I have edited the post. – Henry Henrinson Jul 04 '12 at 08:42
-
"Why do you want to _execute_ a Scala program? Scala is meant to only for proving that your C.S. thesis compiles." -- quote by me ;) – conny Jan 16 '19 at 06:56
4 Answers
6
Take a look at ej-technologies the creators of JProfiler, they have a couple of products that might be useful to you, quoting from their product page:
install4j A cross platform Java installer that generates native installers and application launchers for your Java applications.
exe4j A Java exe maker that helps you integrate your Java applications into the Windows operating environment.
These are both commercial products and although I haven't used them, I have used JProfiler for many years.

Community
- 1
- 1

Don Mackenzie
- 7,953
- 7
- 31
- 32
3
I've heard of this one: Lauch4j.
According to the site:
It's possible to wrap applications on Windows, Linux, Mac OS X and Solaris

Dielson Sales
- 1,715
- 1
- 20
- 25
2
IzPack plugin for SBT might be useful.
Even scala itself uses it: They use IzPack

Petro Semeniuk
- 6,970
- 10
- 42
- 65