我一直试图根据this example,制作安装程序,但我似乎遇到了一些棘手的问题。我开发的示例安装程序已正确编译并按原样安装,但是当我创建更高级别的引导程序和安装程序时,我遇到了麻烦 - WPF UI没有正确挂钩。
当我运行安装程序时,它为我提供了一个通用安装程序,其中包含一个标题为安装程序安装所需的Microsoft .NET Framework的红色磁盘。运行此操作会导致无法卸载的Window的安装/卸载条目 - 它似乎也没有删除有效负载,只是尝试安装.Net Framework。
关注顶级wix文件,感谢您的关注。
Bundle.wxs - 引导程序设置的一部分
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:util="http://schemas.microsoft.com/wix/UtilExtension" xmlns:bal="http://schemas.microsoft.com/wix/BalExtension">
<Bundle Name="Jeremiah's Test Installer" Version="1.0.0.0" Manufacturer="Starkey" UpgradeCode="5a714642-7857-4582-8bae-80fd6d8ec77a">
<BootstrapperApplicationRef Id="ManagedBootstrapperApplicationHost">
<Payload SourceFile="..\TestWPF003\bin\Release\TestWPF003.dll"/>
<Payload SourceFile="..\TestWPF003\bootstrapper.config"/>
<Payload SourceFile="C:\Program Files (x86)\WiX Toolset v3.9\SDK\Microsoft.Deployment.WindowsInstaller.dll"/>
</BootstrapperApplicationRef>
<Chain>
<!-- TODO: Define the list of chained packages. -->
<!-- <MsiPackage SourceFile="path\to\your.msi" /> -->
<PackageGroupRef Id='Netfx4Full' />
<MsiPackage SourceFile="..\beta\bin\Release\beta.msi" Id="BetaInstallId" Cache="yes" Visible="no"/>
<MsiPackage SourceFile="..\alpha\bin\Release\alpha.msi" Id="AlphaInstallId" Cache="yes" Visible="yes"/>
</Chain>
</Bundle>
<Fragment>
<!-- Managed bootstrapper requires .NET as a dependency, since it was written in .NET.
WiX provides a Bootstrapper for the bootstrapper. The fragment below includes .NET.
For more information or examples see Heath Stewart's blog or the WiX source:
http://blogs.msdn.com/b/heaths/archive/2011/10/28/introducing-managed-bootstrapper-applications.aspx
-->
<WixVariable Id="WixMbaPrereqPackageId" Value="Netfx4Full" />
<WixVariable Id="WixMbaPrereqLicenseUrl" Value="NetfxLicense.rtf" />
<util:RegistrySearch Root="HKLM" Key="SOFTWARE\Microsoft\Net Framework Setup\NDP\v4\Full" Value="Version" Variable="Netfx4FullVersion" />
<util:RegistrySearch Root="HKLM" Key="SOFTWARE\Microsoft\Net Framework Setup\NDP\v4\Full" Value="Version" Variable="Netfx4x64FullVersion" Win64="yes" />
<PackageGroup Id="Netfx4Full">
<ExePackage Id="Netfx4Full" Cache="no" Compressed="yes" PerMachine="yes" Permanent="yes" Vital="yes"
SourceFile="C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bootstrapper\Packages\DotNetFX40\dotNetFx40_Full_x86_x64.exe"
DetectCondition="Netfx4FullVersion AND (NOT VersionNT64 OR Netfx4x64FullVersion)" />
</PackageGroup>
</Fragment>
</Wix>
答案 0 :(得分:0)
我认为这是因为您错过了BootstrapperCore.config
文件,您无法将其重命名为其他内容。
<Payload SourceFile="..\TestWPF003\BootstrapperCore.config"/>
编辑:我不认为name属性是问题,但具体来说文件名必须是 BootstrapperCore.config ,请尝试使用我在上面指定的行:)