Fossil SCM

fossil-scm / compat / zlib / contrib / iostream3 / test / add_subdirectory_test.cmake.in
Blame History Raw 26 lines
1
cmake_minimum_required(VERSION 3.12...3.31)
2
3
project(
4
iostream_add_subdirectory
5
LANGUAGES CXX
6
VERSION @iostreamV3_VERSION@)
7
8
option(ZLIB_IOSTREAM3_BUILD_SHARED "" @ZLIB_IOSTREAM3_BUILD_SHARED@)
9
option(ZLIB_IOSTREAM3_BUILD_STATIC "" @ZLIB_IOSTREAM3_BUILD_STATIC@)
10
option(ZLIB_IOSTREAM3_BUILD_TESTING "" OFF)
11
12
add_subdirectory(@iostreamV3_SOURCE_DIR@ ${CMAKE_CURRENT_BINARY_DIR}/iostream3)
13
14
set(IOSTREAM_SRCS
15
@iostreamV3_SOURCE_DIR@/test.cc)
16
17
if(ZLIB_IOSTREAM3_BUILD_SHARED)
18
add_executable(test_example ${IOSTREAM_SRCS})
19
target_link_libraries(test_example IOSTREAMV3::IOSTREAMV3)
20
endif(ZLIB_IOSTREAM3_BUILD_SHARED)
21
22
if(ZLIB_IOSTREAM3_BUILD_STATIC)
23
add_executable(test_example_static ${IOSTREAM_SRCS})
24
target_link_libraries(test_example_static IOSTREAMV3::IOSTREAMV3STATIC)
25
endif(ZLIB_IOSTREAM3_BUILD_STATIC)
26

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button