mirror of
https://github.com/Naios/continuable.git
synced 2025-12-06 08:46:44 +08:00
Make the function2 dependency available when not building the unit-tests
This commit is contained in:
parent
22d7404970
commit
05a4ab7e11
@ -5,6 +5,12 @@ project(continuable C CXX)
|
||||
set(THREADS_PREFER_PTHREAD_FLAG ON)
|
||||
find_package(Threads REQUIRED)
|
||||
|
||||
if (CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR)
|
||||
set(CONTINUABLE_UNIT_TESTS ON)
|
||||
endif()
|
||||
|
||||
add_subdirectory(dep)
|
||||
|
||||
# continuable-base
|
||||
add_library(continuable-base INTERFACE)
|
||||
|
||||
@ -52,7 +58,7 @@ if (CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR)
|
||||
|
||||
include(cmake/CMakeLists.txt)
|
||||
|
||||
add_subdirectory(dep)
|
||||
|
||||
add_subdirectory(examples)
|
||||
add_subdirectory(test)
|
||||
endif ()
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
if(NOT TARGET gtest)
|
||||
if(CONTINUABLE_UNIT_TESTS AND NOT TARGET gtest)
|
||||
add_subdirectory(googletest)
|
||||
endif()
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user