-
Notifications
You must be signed in to change notification settings - Fork 5
/
CMakeLists.txt
70 lines (68 loc) · 1.39 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
63
64
65
66
67
68
69
70
cmake_minimum_required(VERSION 3.30)
set(CMAKE_EXPERIMENTAL_CXX_IMPORT_STD "0e5b6991-d74f-4b3d-a41c-cf096e0b2508")
set(CMAKE_CXX_MODULE_STD TRUE)
project(co_uring_http LANGUAGES CXX)
set(CMAKE_EXPORT_COMPILE_COMMANDS TRUE)
add_library(${CMAKE_PROJECT_NAME})
target_sources(
${CMAKE_PROJECT_NAME}
PUBLIC
FILE_SET CXX_MODULES FILES
src/common/deferred_initialization.cppm
src/common/lib.cppm
src/coroutine/lib.cppm
src/coroutine/spawn.cppm
src/coroutine/task.cppm
src/coroutine/thread_pool.cppm
src/coroutine/trait.cppm
src/coroutine/wait.cppm
src/http/lib.cppm
src/http/message.cppm
src/http/server.cppm
src/io/buf_ring.cppm
src/io/constant.cppm
src/io/error.cppm
src/io/file.cppm
src/io/io_uring.cppm
src/io/lib.cppm
src/io/socket.cppm
src/lib.cppm
)
target_compile_features(
${CMAKE_PROJECT_NAME}
PRIVATE cxx_std_23
)
target_compile_options(
${CMAKE_PROJECT_NAME}
PRIVATE -pedantic
PRIVATE -Wall
PRIVATE -Wextra
)
target_compile_definitions(
${CMAKE_PROJECT_NAME}
PRIVATE __cpp_concepts=202002L
)
add_executable(main)
target_sources(
main
PRIVATE src/main.cpp
)
target_link_libraries(
main
PRIVATE ${CMAKE_PROJECT_NAME}
PRIVATE uring
)
target_compile_features(
main
PRIVATE cxx_std_23
)
target_compile_options(
main
PRIVATE -pedantic
PRIVATE -Wall
PRIVATE -Wextra
)
target_compile_definitions(
main
PRIVATE __cpp_concepts=202002L
)