如何无法链接到msvcr100.dll? [英] How to not link against msvcr100.dll?

查看:136
本文介绍了如何无法链接到msvcr100.dll?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Visual Studio 10中编译项目,编译可执行文件运行在win 7,但它不工作在win xp因为缺少msvcrt100.dll。
我试图使用/ NOTDEFAULTLIB,但它也删除了我使用的一些其他外部lib。
有没有办法连接到最新的Microsoft运行时库?



提前感谢。



要执行此操作,请转到C / C ++属性 - >解决方案

>代码生成并在运行库下从下拉菜单中选择多线程(/ MT)或多线程调试(/ MTd)。请注意,一旦使用静态运行时库,您链接的所有其他库代码也必须使用相同的设置。您还可能必须向链接器添加其他库 - >附加依赖关系下的输入。


I am compiling project in Visual Studio 10, compiled executable runs fine on win 7 but it doesnt works on win xp because of missing msvcrt100.dll. I tried to use "/NOTDEFAULTLIB" but it also removes some other external libs that i use. Is there way to not link against latest Microsoft runtime library ?

Thanks in advance.

解决方案

To not link against the DLL you must link against the runtime statically.

To do this, go to C/C++ Properties -> Code Generation and under Runtime Library select Multi-threaded (/MT) or Multi-threaded Debug (/MTd) from the drop-down. Note, once you're using a static runtime library all of your other library code you link against must also be built with the same setting. And you will also likely have to add additional libraries to the Linker -> Input under Additional Dependencies.

这篇关于如何无法链接到msvcr100.dll?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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