Search code examples
javamacosantinstallationlaunch4j

Creating Windows application installer in Mac OS with embedded JRE


I have an executable Jar file which is runnable on both Mac and Windows. I want to create an Installer with embedded JRE for windows. I mean the installer application should be either one '.exe' or '.msi' file. Since our development environment is on Mac OS, I want to find a Windows installer maker which works inside Mac. Then, I am able to integrate it to our scripts.

What I have done so far:

I've used 'launch4j'. I managed to create a '.exe' installer of our application with nice integration with our 'ant' scripts. But, the problem is that the embedded JRE is not located inside '.exe' file. It's beside the file. I want to have only one installer file.

What I have thought so far:

There are 2 options if I am right:

  • Find another solution instead of 'launch4j' with nicer installer making with real embedded JRE.
  • Try to find an Windows installer maker for Mac OS to combine the output of the 'lanuch4j' with the neighboring JRE and build one exe/msi file.

Actually, I couldn't find any solution to make all this happen in Mac OS.


Solution

  • I am not aware of any other installer maker for Windows that can run on Mac OS. What you could do is to setup a VM for Windows that runs on your Mac OS, and in that VM use a tool like Advanced Installer. It has a tutorial that shows you how to build such an installer: http://www.advancedinstaller.com/user-guide/tutorial-java.html