大家好,谁能告诉我如何在我的 wix 安装程序的 Bootstrap 中引用 vcredist_x86.exe
文件。
我已经尝试过这个:
<ItemGroup>
<BootstrapperFile Include="vcredist_86">
<ProductName>Microsoft Visual C++ Redistributables</ProductName>
</BootstrapperFile>
</ItemGroup>
<Target Name="AfterBuild">
<GenerateBootstrapper ApplicationFile="$(TargetFileName)" ApplicationName="Server Setup" BootstrapperItems="@(BootstrapperFile)" ComponentsLocation="Relative" CopyComponents="True" OutputPath="$(OutputPath)" Path="C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bootstrapper\" />
</Target>
但我的错误是:
warning MSB3155: Item 'vcredist_86' could not be located in 'C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bootstrapper\'.
我认为这一行是问题所在,但我不知道要输入的正确名称,并且在任何地方都找不到它:
<BootstrapperFile Include="vcredist_86">
最佳答案
查看 C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bootstrapper\Packages 并找到相应的文件夹(例如:vcredist_x86)。然后打开product.xml 文件并使用作为ProductCode 列出的任何内容。
例如:
ProductCode="Microsoft.Visual.C++.10.0.x86"
关于Wix Visual C++ Redistributables 与 Bootstrapper,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12162704/