diff --git a/projects/clr/CMakeLists.txt b/projects/clr/CMakeLists.txt index cc9cf16542..879debac4a 100644 --- a/projects/clr/CMakeLists.txt +++ b/projects/clr/CMakeLists.txt @@ -28,6 +28,10 @@ if (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") add_compile_options("/wd4267" "/wd4244" "/wd4996") string(REPLACE "/GR" "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS}) string(REPLACE "/W3" "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS}) + if (CMAKE_BUILD_TYPE STREQUAL "Debug") + add_compile_options(/MTd) + add_compile_options(-D_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH) + endif() endif() option(CLR_BUILD_HIP "Build HIP" OFF) option(CLR_BUILD_OCL "Build OCL" OFF)