Distributing VC++ Redist… running installer when already installed causes problems

与世无争的帅哥 提交于 2019-12-03 03:28:43
Kyle Alons

Try the /q flag http://support.microsoft.com/kb/227091 (assuming you're installing it via calling msiexec.exe on their redistributable)

rogerdpack

For some reason none of the above answers worked for me. This did, however:

[Run]
Filename: {tmp}\vcredist_x86.exe; Parameters: "/passive /Q:a /c:""msiexec /qb /i vcredist.msi"" "; StatusMsg: Installing 2010 RunTime...
[Files]
Source: vendor/vcredist_x86.exe; DestDir: {tmp}

I got the hint for it by running vcredist_x86.exe /?, as noted at the bottom of this thread: http://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/a8d4d5b4-7927-4c86-95e8-3cd8b3018ae8/

As a further note, another possible option for redistribution is to just static link against (your version of) the msvcrt see comments in http://blogs.msdn.com/b/vcblog/archive/2007/10/12/how-to-redistribute-the-visual-c-libraries-with-your-application.aspx (though MS apparently frowns on this type of static linking, at least you won't need a dll).

Distributing the Visual C++ Runtime Libraries (MSVCRT) may also be useful.

Also note that if you can guarantee you'll have control, you can just include msvcr100.dll in the same directory as your executable and that would work, too, though not a very standard solution.

This thread resolved my issues:

(taken from the comment in the other answer)

angularsen

Although not for Inno installer, this related question provides a solution for Visual Studio 2010 setup project. The issue is due to the SP1 of vcredist changed the product code, while Visual Studio uses the old code. That is why the already installed check fails.

Visual C++ 2010 Runtime Libraries prerequisite keeps popping up on a VS 2010 created installer

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