对于 Bootstrapper,FileCheck 元素在 System32 中的 64 位操作系统上找不到文件
您好,我正在尝试从 WiX 生成的 MSI 创建一个新的 boostrapper。我已经完成了一项并且有效,但现在我需要做另一项检查文件上的文件版本。
根据 MSDN 我应该使用文件检查元素。
<InstallChecks>
<FileCheck Property="VersionDll" FileName="cimwin32.dll" SearchPath="wbem" SpecialFolder="SystemFolder"/>
</InstallChecks>
但这对我不起作用。
生成的日志显示:
Running check with folder 'C:\Windows\System32\wbem' and file 'cimwin32.dll'
Attempting to find file 'C:\Windows\System32\wbem\cimwin32.dll'
Could not find file 'cimwin32.dll' in folder 'C:\Windows\System32\wbem'
Not setting value for property 'VersionDll'
即使日志文件中列出的路径是正确的!非常混乱。任何帮助将不胜感激,
我不确定这是否重要,但我在 64 位 Windows 7 操作系统上看到了这一点。
更新 根据 Micheal 的帮助和一些测试,这是 64 位计算机上的文件重定向和引导程序中的 FileCheck 标记的问题。无论架构如何,我都需要检查 Windows/System32/wbem/cimwin32.dll
Hi I am attempting to create a new boostrapper from my WiX generated MSI. I have done one and it worked but now I need to do another where I check the file version on the file.
According to MSDN I should use the FileCheck element.
<InstallChecks>
<FileCheck Property="VersionDll" FileName="cimwin32.dll" SearchPath="wbem" SpecialFolder="SystemFolder"/>
</InstallChecks>
But it doesn't work for me.
The log generated says:
Running check with folder 'C:\Windows\System32\wbem' and file 'cimwin32.dll'
Attempting to find file 'C:\Windows\System32\wbem\cimwin32.dll'
Could not find file 'cimwin32.dll' in folder 'C:\Windows\System32\wbem'
Not setting value for property 'VersionDll'
Even though the listed path in the log file is correct! Very confusing. Any help would be appreciated
I am not sure if this matters or not but I am seeing this on a 64 Windows 7 OS.
UPDATE
Based off of help from Micheal and some testing this is a problem with File Redirection on 64 bit machines and the FileCheck tag in the bootstrapper. Regardless of architecture I need to check Windows/System32/wbem/cimwin32.dll
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
好吧。我得到了它。感谢 Michael Urman 与我一起集思广益。这让我想到了 64 位操作系统上的文件重定向,而我并不知道发生了这种情况。
为了使引导程序能够访问 64 位操作系统上的 32 位目录,它需要使用 System32 的别名 Sysnative
更多信息
所以我刚刚创建了另一个文件检查。一台适合 32 岁,一台适合 64 岁,我已经准备好了。
Alright. I got it. Thanks to Michael Urman for brainstorming with me. It got me thinking about File Redirection on 64bit OSs that I didn't know happened.
For the bootstrapper to get access to a 32 bit directory on a 64 bit OS it needs to use the alias Sysnative for System32
More info
So I just created another file check. One for 32 and one for 64 and I am up and going.