NSIS Scriptable Installer
I was recently tipped off by Tom Wheeler to use NSIS for client installers. Yea I know, "what about webstart?". Well some applications need to be brain dead. In fact one project we struggled with users messing up their JRE installs which caused our web start application to fail.
Additionally alot of enterprises have nightly build and or general release processes. What this means is that the person that is doing the build should build from one environment and have the entire suite built accordingly. For example on one project there are 100s of items built on linux as well as three or four Swing applications. However the user shouldn't have to go to a windows machine and perform the installer generation for the Swing applications.
Anyway, I struggled with getting it working on a linux machine, mainly because I was confused by what the existing documentation suggested. This process should work to get you going on version 2.15. I don't think it will change much.
The following was performed in my home directory chrisp@paulgl
I downloaded the release of 2.15 and the source of 2.15.
1) Downloads
drwxrwxr-x 11 chrisp chrisp 4096 Apr 5 14:40 nsis-2.15
drwxrwxr-x 13 chrisp chrisp 4096 Apr 5 16:25 nsis-2.15-src
2) Patched one file per a forum comment:
Use the latest CVS version of SConstruct.
http://cvs.sourceforge.net/viewcvs.py/nsis/NSIS/SConstruct?r1=1.64&r2=1.65
File patched was nsis-2.15/SConstruct
3) cd nsis-2.15-src
4) scons SKIPSTUBS=all SKIPPLUGINS=all SKIPUTILS=all SKIPMISC=all
5) cp build/release/makensis/makensis ../nsis-2.15/makensis
After all that the nsis-2.15 dir is ready for use on linux.
<target name="win-setup-exe" depends="jar-to-exe">
<exec executable="${nsis.dir}/makensis" >
<arg line="nsis/enablecode.nsi"/>
</exec>
</target>
My ant script called it and I got a windows setup.exe on the linux box that actually worked. Very COOL!
