简体   繁体   English

使用多线程调试DLL(/ MDd)C运行时库构建静态Opencv库

[英]Build the static Opencv library with multi-threaded debug DLL (/MDd) C runtime library

I am now trying to build opencv with cmake, and if I use the following command: 我现在正在尝试使用cmake构建opencv,如果我使用以下命令:

cmake -DBUILD_SHARED_LIBS=OFF ..

I can build a static OPENCV libary. 我可以构建一个静态OPENCV库。 However, the built library links C run time library statically. 但是,构建的库静态链接C运行时库。 In VC2010, it uses Multi-threaded Debug (/MTd) option. 在VC2010中,它使用多线程调试(/ MTd)选项。 What I expects is to link C run time library dynamically, and that is using /MDd option in VC2010, then what can I do to make it possible? 我期望的是动态链接C运行时库,并且在VC2010中使用/ MDd选项,那么我该怎样做才能实现呢? Thanks. 谢谢。

-DBUILD_WITH_STATIC_CRT=OFF添加到CMake命令行:

cmake -DBUILD_SHARED_LIBS=OFF -DBUILD_WITH_STATIC_CRT=OFF ..

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Visual C++:作为“多线程调试 DLL”的发布模式运行时库 - Visual C++: Runtime Library of Release Mode as 'Multi-threaded Debug DLL' 链接到多线程调试DLL库时链接错误 - Linking error while linking to Multi-threaded Debug DLL library 有没有一种方法可以用单线程版本库编译多线程C ++程序? - Is there a way to compile multi-threaded C++ program with single-threaded version library? 包含静态库的Visual Studio C ++调试DLL - Visual Studio C++ Debug DLL containing static library Qt槽没有在多线程DLL中执行 - Qt slots not executed in a multi-threaded DLL 如何将整个 openCV 库构建为 static 库? - How to build the whole openCV library into a static library? Windows CE 6.0和运行时链接到调试DLL / MDd - Windows CE 6.0 and runtime link to Debug DLL /MDd 将公共语言运行时 (/clr) .dll 链接到静态链接到 C/C++ 运行时库的静态库 - Linking a Common Language Runtime (/clr) .dll to static libraries statically linked to the C/C++ Runtime Library 调试生成中的TRE模糊正则表达式库运行时错误:缺少MSVCP90.dll - TRE fuzzy-regex library runtime-error in debug build: MSVCP90.dll is missing 分析C ++多线程应用程序 - Profiling C++ multi-threaded applications
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM