We just migrated our installer from WiX 2.x to WiX 3.6 and started using Burn. Previously, we were installing the Visual C++ redistributable by including the .msm files from C:\Program Files\Common Files\Merge Modules
to our MSI. Those files are always in sync with the one we use to build our product (they are updated frequently by Microsoft to include security fixes).
Now, we would like to have the Visual C++ redistributable downloaded only if required by using the Burn framework. However, Burn does not define a MsmPackage
element to place inside Chain
.
What is the best approach for deploying Visual C++ redistributable using Burn?
How to extract a Burn (WiX) based installer / installation / setup file 1 Install the most recent WiX Tool set 2 Add the “bin” folder of the WiX Toolset to the PATH Environment Variable (you do not have to but it makes life easier) 3 Run the following command to extract your burn based installer: dark [burnbasedinstaller].exe -x [OutPutFolder]
Why use a WIX Bootstrapper project? In our project there are so many things that we need to install before our software will be installed. At that time we can use this to bundle the prerequisites (like .Net Framework, SQL etc.) of Software or Website. Using this we can put all the necessary things into a single package so it is easy to manage.
Applications written using the .NET Framework often need to bundle the .NET framework and install it with their application. Wix 3.6 and later makes this easy with Burn. Follow the instructions in Building Installation Package Bundles. Add a reference to WixNetFxExtension to your bundle project.
Add a reference to WixNetFxExtension to your bundle project. Add a PackageGroupRef element to your bundle's chain that references the .NET package required by your application. For a full list, see [WixNetfxExtension] (../../customactions/wixnetfxextension.html). Ensure that the PayloadGroupRef is placed before any other packages that require .NET.
Merge modules can only be merged into an .msi; they can't be installed independently. You can use ExePackage
to install the appropriate vcredist*.exe.
This is what you should do:
Now 2) will ensure that in upgrade scenarious the MSI won't be installed, or if it is an external payload, it won't be downloaded.
The problem with packaging vcredist*.exe
is that some user might think that it is an independent install and uninstall it and break your application.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With