Building on Windows

NSIS

Previous | Contents | Next

G.2 Building on Windows

SCons will automatically detect Microsoft Visual C++. If you are looking for a free compiler to compile NSIS, we recommend Microsoft Visual C++ 2005 Express Edition.

When using the Microsoft Visual C++ Toolkit 2003, add MSTOOLKIT=yes to the build command line:

scons MSTOOLKIT=yes

In case of errors about the compiler or the Platform SDK not being found, use:

set MSSDK=C:\Path\To\Platform SDK
set VCToolkitInstallDir=C:\Path\To\VCToolkit
scons MSTOOLKIT=yes

The open-source MinGW can also be used to for building but this results in noticeably larger installers. Borland C++ or Open Watcom C/C++ might also work, but haven't been tested.

To compile the documentation as a CHM file, hhc.exe must be in the PATH. It is available as part of HTML Help Workshop.

To build NSIS Menu, install wxWidgets 2.8, create an environment variable named WXWIN containing the path to the installation directory of wxWidgets, run Contrib\NSIS Menu\wx\wxbuild.bat and build NSIS as usual.

Important notes for Microsoft Visual C++ 6.0 users: The 2003 Platform SDK must be installed before building, you can download it here or order it on CD. Because of flaws in the libraries distributed with Microsoft Visual C++ 6.0, not installing the Platform SDK will result in crashes when using the CopyFiles command. See this forum topic for more information. Installing the Processor Pack is highly recommended to decrease the size of the installer overhead.

Important note for Microsoft Visual C++ 2012 users: Installers generated using this release and beyond will not be able to run on Windows 9x or Windows 2000. The minimum requirement for 2012 is Windows XP.

Previous | Contents | Next