Including a runtime (vcredist_x86.exe) as part of an installer

寵の児 提交于 2019-12-25 03:26:31

问题


I need to include a runtime as part of a project installer.

I was having trouble including it, as an error saying "an installation is already in progress" was appearing, due to the fact that I was essentially trying run an msi from within an msi.

I managed to get over this by including it in the "OnAfterInstall" event, however it appears now that it is not being installed on upgrades, only on fresh installs.

Can anyone offer any advice?

Thanks


回答1:


You don't specify what version of the Visual C++ Runtime, but this may work:

Visual Studio Installer Projects provide a prerequisites setting which is pre-populated with a list of common components. These are .mst files, so they can be merged into your installer. To reach the prerequisites screen, right-click your installer project -> Properties -> Prerequisites. Check the appropriate box in the list and change the option at the bottom to include the prerequisite in the setup program.




回答2:


apparently you should add it as a "merge module" in your MSI http://blogs.msdn.com/b/vcblog/archive/2007/10/12/how-to-redistribute-the-visual-c-libraries-with-your-application.aspx



来源:https://stackoverflow.com/questions/6623183/including-a-runtime-vcredist-x86-exe-as-part-of-an-installer

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!