forked from alibaba/yalantinglibs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
35 lines (29 loc) · 1.06 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
cmake_minimum_required(VERSION 3.15)
project(yaLanTingLibs
VERSION 0.3.9
DESCRIPTION "yaLanTingLibs"
HOMEPAGE_URL "https://github.com/alibaba/yalantinglibs"
LANGUAGES CXX
)
# load pack finder
list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake/Find/)
find_package(Threads REQUIRED)
link_libraries(Threads::Threads)
include(cmake/install.cmake)
if(CMAKE_PROJECT_NAME STREQUAL "yaLanTingLibs") # if ylt is top-level project
# add include path
include_directories(include)
include_directories(include/ylt/thirdparty)
include_directories(include/ylt/standalone)
include_directories(src/include)
include(cmake/utils.cmake)
include(cmake/build.cmake)
include(cmake/develop.cmake)
# add project config, such as enable_ssl.
include(cmake/config.cmake)
# add project's source such as unit test, example & benchmark
include(cmake/subdir.cmake)
else ()
# add project config, such as enable_ssl.
include(cmake/config.cmake)
endif()