From 48d64b0842f5b13ba197d759d95c7929072efd74 Mon Sep 17 00:00:00 2001 From: bubnikv Date: Sat, 26 Jan 2019 14:12:57 +0100 Subject: [PATCH] Fixed compilation on Visual Studio in Debug mode. --- src/libnest2d/CMakeLists.txt | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/libnest2d/CMakeLists.txt b/src/libnest2d/CMakeLists.txt index 7853a48d5..514498ee8 100644 --- a/src/libnest2d/CMakeLists.txt +++ b/src/libnest2d/CMakeLists.txt @@ -70,10 +70,12 @@ if(TBB_FOUND) # The Intel TBB library will use the std::exception_ptr feature of C++11. target_compile_definitions(libnest2d INTERFACE -DTBB_USE_CAPTURED_EXCEPTION=0) - find_package(Threads REQUIRED) - target_link_libraries(libnest2d INTERFACE ${TBB_LIBRARIES} ${CMAKE_DL_LIBS} - Threads::Threads - ) + target_link_libraries(libnest2d INTERFACE tbb) + # The following breaks compilation on Visual Studio in Debug mode. + #find_package(Threads REQUIRED) + #target_link_libraries(libnest2d INTERFACE ${TBB_LIBRARIES} ${CMAKE_DL_LIBS} + # Threads::Threads + # ) else() find_package(OpenMP QUIET)