wixtoolset / issues

WiX Toolset Issues Tracker
http://wixtoolset.org/
129 stars 24 forks source link

Document how to include NetFx redist packages in how-to #4520

Closed wixbot closed 8 years ago

wixbot commented 10 years ago

With WiX Toolset 3.9.901:

In a custom BA I'm trying to use NetFxExtension to automatically detect and install the offline version of the .NET Framework 4.5.1 by using . I have included the setup also as payload as "redist\NDP451-KB2858728-x86-x64-AllOS-ENU.exe" as well as setting the variables:

<WixVariable Id="WixMbaPrereqPackageId" Value="Netfx451Full" />
<WixVariable Id="WixMbaPrereqLicenseUrl" Value="redist\Netfx_eula451.rtf" />

<Payload Name='redist\NDP451-KB2858728-x86-x64-AllOS-ENU.exe' SourceFile='..\redist\NDP451-KB2858728-x86-x64-AllOS-ENU.exe'/>
<Payload Name='redist\Netfx_eula451.rtf' SourceFile='..\redist\Netfx_eula451.rtf'/>

The resulting bootstrapper executable shows the ":NET Framework required" dialog on startup (with EULA link correctly working), but then never actually starts the the NET 4.5.1 setup. From the BA logfile, on Win 7.1 with just NET 3.5:

[093C:0A4C][2014-09-03T15:35:59]i000: Registry key not found. Key = 'SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full'
[093C:0A4C][2014-09-03T15:35:59]i052: Condition 'NETFRAMEWORK45 >= 378675' evaluates to false.

[093C:0A4C][2014-09-03T15:35:59]i101: Detected package: NetFx451Redist, state: Absent, cached: None

[093C:0A4C][2014-09-03T15:36:06]w321: Skipping dependency registration on package with no dependency providers: NetFx451Redist

[093C:0A4C][2014-09-03T15:36:06]i201: Planned package: NetFx451Redist, state: Absent, default requested: Present, ba requested: None, execute: None, rollback: None, cache: No, uncache: No, dependency: None

[093C:0A4C][2014-09-03T15:36:26]i000: The prerequisites were already installed. The bootstrapper application will not be reloaded to prevent an infinite loop.

I suspect this might be caused by a missing part in NetFx451.wxs - compared to the NetFx4.5.wxs (files from wix39-debug.zip) it has no

<Fragment> <util:RegistrySearch Id="NETFRAMEWORK45" ...

The same approach works correctly with NetFx45Redist

Originally opened by js69

wixbot commented 10 years ago

Please add a full log so we can see everything leading up to the plan.

Originally posted by barnson

wixbot commented 10 years ago

In order for the prereq BA to install a package, the package's Id must be assigned to the WixMbaPrereqPackageId WixVariable (you have Netfx451Full but it should be NetFx451Redist, the same as your PackageRef). Or you would have to set the bal:PrereqSupportPackage attribute on the package to 'yes' and make sure the install condition is true.

Originally posted by rseanhall

wixbot commented 10 years ago

Thanks a lot, shall! That was the mistake I made.

I'd like to suggest to add this info to the documentation (as well as the necessity to include the NET installer at Redist\NDP451-KB2858728-x86-x64-AllOS-ENU.exe) because I only found the WixVariables mentioned in a stackoverflow thread.

Originally posted by js69

wixbot commented 10 years ago

We'd take this if we rebuild v3.9.

wixbot commented 10 years ago

Should go to v3.10.

Originally posted by barnson Status changed from Open to Untriaged

wixbot commented 10 years ago

Release changed from v3.9 to v3.10

wixbot commented 10 years ago

AssignedTo set to bobarnson

wixbot commented 9 years ago

Originally changed by barnson Resolution set to fixed Status changed from Open to Resolved