且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

WiX - 安装先决条件和第 3 方应用程序

更新时间:2023-11-14 18:26:10

请参阅 WiX 3.7 文档Building Installation Package Bundles".如果您使用 MSBuild、SharpDevelop 或 Visual Studio(非 Express),则可以使用 WiX Bootstrapper 项目模板.如果您更喜欢自己调用工具集命令行工具,它们就像构建 MSI 文件一样.

See the WiX 3.7 docs on "Building Installation Package Bundles". If you are using MSBuild, SharpDevelop or Visual Studio (non-Express), you can use the WiX Bootstrapper project template. If you prefer to call the toolset command-line tools yourself, they are candle and light, just like for building MSI files.

请参阅有关如何:使用 Burn 安装 .NET Framework"的 WiX 3.7 文档.注意:WiX 为 .NET 4.0 提供了两个预定义的包,都在安装时从 Microsoft 下载.一个是完整包,另一个是用户系统需要下载的下载器包.如果您不想让您的安装程序依赖 Internet 访问,您可以编写自己的包,因为您必须处理捆绑的任意 exe.显然,WiX 源代码可以帮助处理 .NET 4.0 包,因为它具有您需要的检测条件、安装命令和卸载命令.

See the WiX 3.7 docs on "How To: Install the .NET Framework Using Burn". Note: WiX offers two pre-defined packages for .NET 4.0, both download from Microsoft at install-time. One is the full package, the other is the downloader package that downloads just is needed on the user's system. If you'd rather not have your installer depend on Internet access, you can write your own package as you have to do with any arbitrary exe that you bundle. Obviously, the WiX source code can help with the .NET 4.0 packages as it has the detect condition, install command, and uninstall command that you'd need.

请参阅其他每个软件包的安装文档,以了解您应该将哪些内容放入它们的检测条件、安装命令和卸载命令中.而且,您还可以选择是否在每个包中放置下载 URL.

See the installation docs for each of the other packages to find out what you should put into their detect conditions, install commands, and uninstall commands. And, again, you'd have the choice of putting a download URL in each package or not.

<PackageGroup Id="SQLExpressCE">
    <!-- Per http://support.microsoft.com/kb/974247, on a 64-bit system both 32-bit and 64-bit packages must be installed and be the same version. -->
    <MsiPackage
          Visible="yes"
          Cache="no"
          Compressed="no"
          ForcePerMachine="yes"
          Permanent="yes"
          Vital="yes"
          SourceFile=".prerequisitesSSCERuntime-ENU.msi" />
    <MsiPackage
          Visible="yes"
          Cache="no"
          Compressed="no"
          ForcePerMachine="yes"
          Permanent="yes"
          Vital="yes"
          SourceFile=".prerequisitesSSCERuntime-ENU-x64.msi"
          InstallCondition="VersionNT64" />
</PackageGroup>

WiX 刻录故障排除

Burn 会为其自身以及它运行的任何 MsiPackages 创建一个日志文件.检查您的 %TEMP% 文件夹.

WiX Burn Troubleshooting

Burn creates a log file for itself as well as any MsiPackages it runs. Check your %TEMP% folder.