-
Notifications
You must be signed in to change notification settings - Fork 97
[BUG] 编译时:error LNK2038: 检测到“RuntimeLibrary”的不匹配项 #13
Comments
Debug 的项目配置缺少宏定义 EN: Debug's project configuration is missing the macro definition _DEBUG (usually, VS will have this macro by default) |
但是我觉得是ucxxrt.lib是用release编译的,而我的是用debug的,所以出现了mt和mtd不对应的问题,运行库应该不是由宏来决定的吧,我切换到release编译就成功了 |
ucxxrt的配置并没有错。_DEBUG 宏是STL的头文件里面需要的,头文件这部分并不会编译到ucxxrt |
更何况,错误提示已经指出了 ucxxrt 是 debug 的,而你的 ntloader 因为缺少
|
我更改了运行库,解决了,谢谢啦awa |
Describe the bug
编译时出现
ucxxrt.lib(xthrow.obj) : error LNK2038: 检测到“RuntimeLibrary”的不匹配项: 值“MTd_StaticDebug”不匹配值“MT_StaticRelease”
和ucxxrt.lib(throw_bad_alloc.obj) : error LNK2038: 检测到“RuntimeLibrary”的不匹配项: 值“MTd_StaticDebug”不匹配值“MT_StaticRelease”
To Reproduce
Steps to reproduce the behavior:
1.切换到Debug选项
2.编译
Expected behavior
出现LNK2038错误
Screenshots

Desktop (please complete the following information):
Additional context
The text was updated successfully, but these errors were encountered: