MSI 补丁创建问题
我们的产品(软件包)的新版本最近已发布。为了扩展功能,我们后来开发了一个插件。现在我们想要使用 MSI 补丁 (msp) 将这些文件(两个新文件和现有文件的更新版本)部署为修补程序(或更新)。我从 MSDN 网站下载了一个空白 PCP 文件并对其进行了一些更改。更改涉及以下表格:
ImageFamilies
PatchMetadata
PatchSequence
Properties
TargetImages
UpgradedImages
所有其他表格保持空白。
然后,我设法根据软件包管理映像的两个版本使用此 PCP 文件创建一个 msp 文件,这两个版本都是从 Visual Studio 安装项目 (VS 2010) 构建的。这两个msi包之间的区别是我替换了一个文件并添加了两个新文件,但没有别的。我没有更改产品代码 (GUID)、升级代码 (GUID) 或版本号。
然后我尝试在已发布的版本之上安装此 msp 文件。
出现的第一个屏幕要求修复或删除产品。这不是我们想要的。我们希望安装程序就像全新安装一样,包括显示许可协议。如何定义 MSI 补丁的 UI?
在安装补丁的过程中,出现如下错误信息,然后安装失败:
错误 1001。初始化安装时发生异常:System.IO.FileNotFoundException:无法加载文件或程序集“file:///C:\WINDOWS\system32\Files\BPS\TestApp”或其中之一它的依赖项。该系统找不到指定的文件。
BPS 是我们在 [ProgramFilesFolder] 中安装产品的文件夹。我想知道为什么 MSI 试图在“C:\Windows\system32”中搜索安装在 [ProgramFilesFolder] 中的文件。另外,修补程序中更改的文件位于其他位置([CommonAppDataFolder]),而不是在这个“BPS”文件夹中。
谁能帮我解决这些问题吗?如果需要更多信息来确定问题,请告诉我。任何想法、意见、建议将不胜感激。
担
A new version of our product (a software package) has been released recently. To expand functionality, we developed a plugin afterwards. Now we would like to deploy these files (two new files and an updated version of an existing file) as hotfix (or update) with MSI patch (msp). I downloaded a blank PCP file from MSDN website and made some changes in it. The changes involve the following tables:
ImageFamilies
PatchMetadata
PatchSequence
Properties
TargetImages
UpgradedImages
All the other tables remain blank.
Then, I managed to create an msp file with this PCP file based on two versions of the admin image of the software package, both of which were built from Visual Studio setup project (VS 2010). The difference between these two msi packages are that I replaced a file and added two new files in, but nothing else. I didn't change the product code (GUID), the upgrade code (GUID), nor the version number.
Then I was trying to install this msp file on top of the released version.
The first screen appearing is asking to Repair or Remove the product. This is not what we want. We want the installer is like a fresh installation, including showing the licence agreement. How do I define the UI for MSI patch?
During the installation of the patch, I got an error message as below, then the installation failed:
Error 1001. Exception occurred while initializing the installation: System.IO.FileNotFoundException: Could not load file or assembly 'file:///C:\WINDOWS\system32\Files\BPS\TestApp' or one of its dependencies. This system cannot find the file specified.
BPS is the folder where we install our product in [ProgramFilesFolder]. I wondered why MSI was trying to search in "C:\Windows\system32" for files installed in [ProgramFilesFolder]. In addition, the changed files in the hotfix are located in somewhere else ([CommonAppDataFolder]) instead of in this "BPS" folder.
Can anyone help me with these problems? If any more information is needed to identify the issues, please let me know. Any thoughts, advices, suggestions would be very much appreciated.
Dan
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在升级包中增加产品版本。这样,您将使用次要升级的一个小更新。
您还可以尝试使用 MSIEXEC 命令行来应用补丁:
http://msdn.microsoft.com/en-us/library/aa367574(VS.85).aspx
http://msdn.microsoft.com/en-us/library/ aa367575(VS.85).aspx
您的安装程序中是否有某些内容使用该文件?也许是自定义操作?尝试查看日志以查看哪些操作尝试访问该文件。
In the upgrade package increase the Product Version. This way you will use a minor upgrade instead of a small update.
You can also try using the MSIEXEC command line to apply the patch:
http://msdn.microsoft.com/en-us/library/aa367574(VS.85).aspx
http://msdn.microsoft.com/en-us/library/aa367575(VS.85).aspx
Is there something in your installer using that file? Perhaps a custom action? Try looking in the log to see what action tries to access that file.