libvcruntimed.lib(_chkesp_.obj):错误LNK2005:__CRT_RTC_INIT已在libcmtd.lib中定义(_init_.obj) [英] libvcruntimed.lib(_chkesp_.obj) : error LNK2005: __CRT_RTC_INIT already defined in libcmtd.lib(_init_.obj)

查看:800
本文介绍了libvcruntimed.lib(_chkesp_.obj):错误LNK2005:__CRT_RTC_INIT已在libcmtd.lib中定义(_init_.obj)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我将项目地图从VS2008移动到了VS2017。现在我收到此链接器错误。我该如何解决?

解决方案

您好
Susann Miller


感谢您在这里发帖。


>> libvcruntimed.lib(_chkesp_.obj):错误LNK2005:__CRT_RTC_INIT已在libcmtd.lib中定义(_init_.obj)


您正在使用/ MD(使用DLL版本的CRT)编译的代码与使用/ MT编译的代码(使用静态CRT库)混合。请检查您的项目 属性 - > C / C ++ - >代码生成 - >运行时库属性。


有关详细信息,请参阅以下文档。


https://msdn.microsoft.com/en-us/library/2kzt1wy3.aspx


最好的问候,


Baron Bi



I moved my project map from VS2008 to VS2017. Now I get this linker error. How can I resolve it?

解决方案

Hi Susann Miller,

thanks for posting here.

>>libvcruntimed.lib(_chkesp_.obj) : error LNK2005: __CRT_RTC_INIT already defined in libcmtd.lib(_init_.obj)

You are mixing code that was compiled with /MD (use DLL version of CRT) with code that was compiled with /MT (use static CRT library). Please check your project Properties->C/C++->Code Generation->Runtime Library property.

For more information, please refer to this document below.

https://msdn.microsoft.com/en-us/library/2kzt1wy3.aspx

Best Regards,

Baron Bi


这篇关于libvcruntimed.lib(_chkesp_.obj):错误LNK2005:__CRT_RTC_INIT已在libcmtd.lib中定义(_init_.obj)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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