summaryrefslogtreecommitdiff
path: root/dev-cpp/sol2/files/sol2-3.2.2-catch-depend.patch
blob: 2da3c00c161257fb9ef5301c17e5c5afed93ff05 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
Use catch library from system

--- a/tests/runtime_tests/CMakeLists.txt
+++ b/tests/runtime_tests/CMakeLists.txt
@@ -22,12 +22,6 @@
 
 # # # # sol3 tests - runtime tests
 
-if (CMAKE_GENERATOR MATCHES "Visual Studio 14 2015")
-	find_package(Catch 1.12.1 REQUIRED)
-else()
-	find_package(Catch REQUIRED)
-endif()
-
 file(GLOB SOL2_RUNTIME_TEST_SOURCES source/*.cpp)
 source_group(test_sources FILES ${SOL2_RUNTIME_TEST_SOURCES})
 
@@ -38,7 +32,8 @@ function(CREATE_TEST test_target_name test_name target_sol)
 		OUTPUT_NAME ${test_name}
 		EXPORT_NAME sol2::${test_name})
 	target_link_libraries(${test_target_name} 
-		PUBLIC Threads::Threads ${LUA_LIBRARIES} ${CATCH_LIBRARIES} ${target_sol})
+		PUBLIC Threads::Threads ${LUA_LIBRARIES} ${target_sol})
+	target_include_directories(${test_target_name} PRIVATE ${CATCH_INC_DIR})
 	
 	if (MSVC)
 		if (NOT CMAKE_COMPILER_ID MATCHES "Clang")