WiX VC++ Redist 源文件 [CommonFilesFolder]

发布于 2024-08-02 17:06:27 字数 447 浏览 2 评论 0原文

我正在尝试将 Microsoft_VC90_CRT_x86 合并模块添加到我的 WiX 安装程序中,但在指定 SourceFile 时遇到问题。我不想在 make 脚本中的构建范围内复制 .msm 文件,而是想访问它位于构建系统上的 .msm 文件(C:\Program Files\Common Files\Merge Modules)。尽管 [CommonFilesFolder] 是一个“特殊”WiX 变量,但我似乎无法使用它来指定 SourceFile,如下所示:

<Merge Id="VCRedist.34FC990B-37A2-47ba-BC6D-D8E0572850B9" Language="1033"
           SourceFile="[CommonFilesFolder]Merge Modules\Microsoft_VC90_CRT_x86.msm" DiskId="1" />

I'm trying to add the Microsoft_VC90_CRT_x86 merge module to my WiX installer but am having an issue specifying SourceFile. Rather than copying the .msm file within the scope of my build in my make script I would like to access the .msm where it lives on the build system (C:\Program Files\Common Files\Merge Modules). Despite [CommonFilesFolder] being a 'special' WiX variable it seems I am unable to use it to specify SourceFile, as below:

<Merge Id="VCRedist.34FC990B-37A2-47ba-BC6D-D8E0572850B9" Language="1033"
           SourceFile="[CommonFilesFolder]Merge Modules\Microsoft_VC90_CRT_x86.msm" DiskId="1" />

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

离不开的别离 2024-08-09 17:06:27

没关系,我是从完全错误的方向看待这个问题的。这些文件夹属性指定目标系统上的位置,而不是构建安装程序的主机上的位置。要访问构建系统上的环境变量,您可以使用: $(env.YourVariable)

如所见 http://wix.sourceforge.net/manual-wix2/preprocessor.htm

Nevermind, I was looking at this from completely the wrong direction. Those folder properties specify locations on the target system and not the host building the installer. To access environment variables on the build system you can use: $(env.YourVariable)

As seen http://wix.sourceforge.net/manual-wix2/preprocessor.htm

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文