1

Can all those steps be accomplished with Inno Setup or do I need additional software?

  • Create a standalone .exe installer for a Java application (either a main JAR plus libraries or a Uber JAR)
  • Bundle a JRE
  • Create a Desktop shortcut so users can start the application manually if necessary
  • Set up the application to run on startup

The answer could be either "yes" or "no, you would need the following additional software...".

Unless it's considered too broad a basic script would be appreciated too, but this is optional.

Piovezan
  • 3,215
  • 1
  • 28
  • 45

1 Answers1

1

Instead of INNO setup, I use NSIS (https://sourceforge.net/projects/nsis/), it's open source software, and very powerful, you can use script.

  • Create a standanlone .exe installer for a Java application (either a main JAR plus libraries or a Uber JAR)

    A: Yes, you need additional software like Launch4j(http://launch4j.sourceforge.net/) , or if you use Eclipse or IDEA there is built-in tools to create executable application

  • Bundle a JRE

    A: Yes, use NSIS script you can bundle JRE installation

  • Create a Desktop shortcut so users can start the application manually if necessary

    A: Yes, use NSIS script you can Create a Desktop shortcut

  • Set up the application to run on startup

    A: Yes, NSIS script you can write windows registry. depends on where you put, Programs defined in Run, RunOnce or StartUp will be loaded in following order: HKLM\Software\Microsoft\Windows\CurrentVersion\RunOnce HKLM\Software\Microsoft\Windows\CurrentVersion\Run HKCU\Software\Microsoft\Windows\CurrentVersion\Run StartUp Folder HKCU\Software\Microsoft\Windows\CurrentVersion\RunOnce

Mark Jeronimus
  • 9,278
  • 3
  • 37
  • 50
J Zou
  • 108
  • 6
  • Thanks for the answer. I don't think Launch4j is necessary. I want to turn the JRE + JAR application bundle into an .exe, not the JAR application alone. Besides, Launch4j does not allow bundling of a JRE. – Piovezan Sep 28 '18 at 22:17
  • Would you have further suggestions in that case? (P.S.: sorry, I sounded a bit dry in my comment, that was unintentional) – Piovezan Sep 28 '18 at 23:43
  • you can use NSIS script to turn the JRE + JAR application bundle into a installation EXE, take a look this answer: https://stackoverflow.com/questions/5000386/nsis-script-for-java-installation – J Zou Sep 28 '18 at 23:53