如何在高级安装程序中安装 VC 可再发行组件?
有许多关于如何在 MSI 文件中包含 VC 运行时的文章和帖子。
我正在使用高级安装程序和 VS2008
有人说使用合并模块;我不确定它们能否正常工作。如果它们在安装过程中在我的服务(依赖于它们)启动之前进入,并且还合并模块,那么它们就会有一个恼人的习惯,要求在卸载时重新启动;
我尝试简单地从 MS 复制 .exe 可重发行包,并使用“安装”下的自定义操作通过 /q 开关执行它们。我可以运行其他像这样的安装程序(例如 SQLITE)并且它可以工作。但MS文件似乎没有安装。它们当然不会出现在程序或更新列表中。
有人知道将 VC2008 运行时合并到 MSI 安装中的简单有效的方法吗?
There are many articles and posts about how to include VC runtimes in an MSI file.
I am using Advanced Installer and VS2008
Some say use Merge Modules; I am not sure they will work correctly ie. if they go in before my services (which depend on them) start up during the install, and also merge modules seme to have have an annoying habit of demanding a reboot on uninstall;
I have tried simply copying the .exe redistrutable packages from MS and using a custom-action under Install to execute them with the /q switch. I can run other installers like this (eg. SQLITE) and it works. But the MS files don't seem to become installed. They certainly don't show up in the Programs or Updates list.
Does anybody know a simple, effective way to incorporate the VC2008 runtimes into an MSI installation?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这通常是通过先决条件完成的。目前,高级安装程序已经为大多数 Visual C++ 可再发行组件预定义了先决条件。因此,您所需要做的就是将它们添加到您的项目中。
This is usually done through prerequisites. Currently Advanced Installer has predefined prerequisites for most Visual C++ redistributables. So all you need to do is add them to your project.
如果您在不使用 /q 开关的情况下将 Visual C++ Redistributable 作为高级安装程序自定义操作的一部分运行,您将看到它失败并显示错误“当前正在进行另一个安装”。
我正在尝试首先安装先决条件(在安装程序的安装阶段之前),或者如果失败,我将使用预定义的先决条件(上面)。但是,当预定义的先决条件需要企业许可证时,要在 VCRedist 上使用 /q,而我没有该许可证。
更新
解决如下:
您的自定义操作对话框应如下所示
If you run the Visual C++ Redistributable as part of Advanced Installer Custom Action without the /q switch you will see it fails with error 'Another installation is currently in progress'.
I am experimenting with installing the pre-requisite first (before install phase of installer) or if that fails, I will use the Predefined Prerequisites (above). However, to have /q on the VCRedist when a Predefined Prerequisite requires an enterprise license, which I don't have ..
Update
Resolved as follows:
Your Custom Action dialog should look something like this