Is there any way to compile the Nullsoft Installer Script (NSI) setup as a MSI package instead of an EXE?
3 Answers
Unfortunately, No.
NSIS lets you create scriptable, procedural installation packages. It's simple, easy to use and has a number of features not present in Windows Installer.
Windows Installer (MSI) creates database driven, transactional installation packages. When written properly a Windows Installer package is very robust, a file gets corrupted/deleted and it will be automatically reinstalled. Windows Installer is aware of UAC and only elevates when required, basically if you're creating software for the corporate market, you will need to provide an MSI.
Check out The Definitive Guide to Windows Installer for a good introduction to understanding MSI.

- 22,080
- 4
- 63
- 85
-
Further: there are a lot of issues with MSI -- you need to create separate installers for x86 versus x64 for one example (among many -- another example: MSI can either always elevate or never elevate -- it can't do both.) -- I imagine that these limitations do not exist with NSIS. – BrainSlugs83 Jan 20 '13 at 10:52
-
1@BrainSlugs83 see the UAC in MSI series. There are no limitations if you write it properly :) http://blogs.msdn.com/b/rflaming/archive/2006/10/01/uac-in-msi-notes-how-to-build-packages-that-work-for-both-standard-user-and-per-machine.aspx – saschabeaumont Jan 25 '13 at 09:44
-
Another bonus is making use of wrapping your MSI inside of NSIS. This is great for when IT departments set the Windows Installer Service to disabled (or manual). You can have your NSIS installer check for this, enable the service & then extract and execute your MSI. None the less it is a good writeup, @saschabeaumont – Damian Nov 03 '14 at 21:45
NSIS installers can be wrapped in MSI files using the MSI Wrapper. It is a small tool that I made for wrapping NSIS and Inno Setup installers. It uses WiX to compile the MSI but there is a GUI to help you instead of an XML file.
It was made because I needed a tool for creating MSI files based on traditional EXE installers. I needed support for uninstall and upgrades and only wanted the wrapped installers to show up once in the Add/Remove programs in the control panel.
I also wanted to be able to pass command line parameters to the wrapped installer when the MSI is installed.
If you want to use it or help me improve it, you can find it at http://www.exemsi.com.
I share the opinion that wrapping an executable installer in an MSI package is not the ideal solution. However, when you already have the exe it can make a lot of sense :-)

- 299
- 3
- 2
-
-
2Holy crap is a good description of that pattern. It doens't make sense at all... sorry. – Christopher Painter Jul 21 '13 at 20:15
-
1No, that does make sense - some corporate deployment methods mandate the use of MSIs, hence needing to wrap as an MSI. – Sean Kearon Jun 23 '21 at 16:27
No (And there are no plans to support .MSI output), try WIX

- 33,834
- 5
- 90
- 130

- 97,548
- 12
- 110
- 164