-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
62 lines (40 loc) · 1.33 KB
/
CMakeLists.txt
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
cmake_minimum_required(VERSION 3.19)
project(katerm)
enable_testing()
if (MSVC)
add_compile_options(/utf-8)
endif()
add_subdirectory(character_width)
# terminal-interface
add_library(terminal-interface INTERFACE)
target_sources(terminal-interface
INTERFACE
src/terminal.cpp
src/terminal_screen.cpp
src/position.cpp
src/terminal_decoder.cpp
src/terminal_instructee.cpp)
target_include_directories(terminal-interface
INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}/include)
set_target_properties(terminal-interface PROPERTIES
CXX_EXTENSIONS OFF
)
target_compile_features(terminal-interface
INTERFACE cxx_std_17)
target_link_libraries(terminal-interface
INTERFACE character_width)
# terminal-static
add_library(terminal-static STATIC
$<TARGET_PROPERTY:terminal-interface,INTERFACE_SOURCES>)
target_include_directories(terminal-static
PUBLIC $<TARGET_PROPERTY:terminal-interface,INTERFACE_INCLUDE_DIRECTORIES>)
target_compile_features(terminal-static
PUBLIC $<TARGET_PROPERTY:terminal-interface,INTERFACE_COMPILE_FEATURES>)
target_link_libraries(terminal-static
PUBLIC $<TARGET_PROPERTY:terminal-interface,INTERFACE_LINK_LIBRARIES>)
add_subdirectory(terminfo)
add_subdirectory(extern/Catch2)
add_subdirectory(tests)
if (KATERM_FUZZING)
add_subdirectory(fuzzing)
endif()