I am having difficulties getting a WiX Custom Bootstrapper Application that targets .NET 4.5 to work.
I have the following line in my Bundle.wxs.
<PackageGroupRef Id="NetFx45Web" />
My BootstrapperCore.config is as follows.
<configuration>
<configSections>
<sectionGroup name="wix.bootstrapper" type="Microsoft.Tools.WindowsInstallerXml.Bootstrapper.BootstrapperSectionGroup, BootstrapperCore">
<section name="host" type="Microsoft.Tools.WindowsInstallerXml.Bootstrapper.HostSection, BootstrapperCore" />
</sectionGroup>
</configSections>
<startup useLegacyV2RuntimeActivationPolicy="true">
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
</startup>
<wix.bootstrapper>
<host assemblyName="FSCustomBA" />
</wix.bootstrapper>
</configuration>
I have tried multiple variations of this.
For example, I have also tried the following.
<host assemblyName="FSCustomBA">
<supportedFramework version="v4\Full" />
<supportedFramework version="v4\Client" />
</host>
And the following.
<host assemblyName="FSCustomBA">
<supportedFramework version="v4.5\Full" />
<supportedFramework version="v4.5\Client" />
</host>
And the following.
<host assemblyName="FSCustomBA">
<supportedFramework version="v4.5" />
</host>
And the following.
<host assemblyName="FSCustomBA">
<supportedFramework version="v4.5\Full" />
</host>
And the following.
<host assemblyName="FSCustomBA">
<supportedFramework version="v4.5\Client" />
</host>
No matter what I have tried, when I run my setup package on a system that does not have .NET 4.5 installed, I am prompted to install .NET 4.5. Once I press the Agree and Install button, the setup package crashes. When I attempt to run the setup package again, it hangs before it displays the buttons. It hangs even after I reboot. I need to restore my system from the system image before it will run again.
Can anyone tell me what I am doing wrong?
I am using WiX 3.10.
Thus far my only clue as to what is going on is the following line in the resulting log files.
[1A14:1778][2016-06-28T10:01:17]i000: The prerequisites were already installed. The bootstrapper application will not be reloaded to prevent an infinite loop.
This is mentioned in another question here on Stack Overflow, Prerequisite bootstrapper application fails to install .NET 4.5. One of the answers to this question suggests that the answer is to set the sku value in the supportedRuntime element of the BootstrapperCore.config file. However, I have done this. Something else is going on.