From 41f810395acee48a2434978ae03d98819a072549 Mon Sep 17 00:00:00 2001 From: Michael Tryby Date: Thu, 28 Feb 2019 17:49:40 -0500 Subject: [PATCH] Fixing windows bulid --- tests/CMakeLists.txt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 9431065..bb521e0 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -44,7 +44,11 @@ foreach(testSrc ${TEST_SRCS}) add_executable(${testName} ${testSrc}) #link to Boost libraries AND your targets and dependencies - target_link_libraries(${testName} ${Boost_LIBRARIES} pthread epanet2 epanet-output) + IF(MSVC) + target_link_libraries(${testName} ${Boost_LIBRARIES} epanet2 epanet-output) + ELSE(TRUE) + target_link_libraries(${testName} ${Boost_LIBRARIES} pthread epanet2 epanet-output) + ENDIF(MSVC) #Finally add it to test execution #Notice the WORKING_DIRECTORY and COMMAND