在我的Release应用程序(VC ++ 2013)中摆脱msvcr120.dll / msvcp120.dll依赖性 [英] Get rid of msvcr120.dll/msvcp120.dll dependency in my Release application (VC++ 2013)

查看:242
本文介绍了在我的Release应用程序(VC ++ 2013)中摆脱msvcr120.dll / msvcp120.dll依赖性的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道对于将msvcr120.dll / msvcp120.dll包含到您的项目中存在一些问题。

I know that there are some questions about how to include msvcr120.dll/msvcp120.dll into your project.

但是我想删除该依赖项。我在Visual Studio 2013的发行版中编译程序。我不依赖于任何VS特定的命令( #pragma 等)或预编译的标头等。

But I want to drop that dependency. I compile the program in Release version, in Visual Studio 2013. I do not depend on any VS-specific commands (#pragma etc.) or precompiled headers etc.

我想将其编译为一个单发行版.exe,并提供给用户,而无需他安装VS的VC ++重新发行版。在Windows 7,Windows 8(可能是Windows XP)上。

I want to compile it to one single release .exe and provide it to user WITHOUT demanding him to install VC++ Redistributes for VS (the user will be working on Windows 7, Windows 8, maybe Windows XP).

有可能吗?如果是,怎么办?

Is that possible? If so, how?

推荐答案

您可以通过设置 / MT将运行时静态链接到项目。 标志。您可以在Visual Studio 2013的项目> [ProjectName]属性... > 配置属性> C / C ++中找到此选项。 > 代码生成> 运行时库。确保仅将其设置为发布配置。

You can statically link the runtime to your project by setting the /MT flag. You can find this option in Visual Studio 2013 under Project > [ProjectName] Properties... > Configuration Properties > C/C++ > Code Generation > Runtime Library. Make sure to only set it for the Release configuration.

这篇关于在我的Release应用程序(VC ++ 2013)中摆脱msvcr120.dll / msvcp120.dll依赖性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆