-
Notifications
You must be signed in to change notification settings - Fork 4
/
CMakeLists.txt
52 lines (41 loc) · 1.3 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
cmake_minimum_required(VERSION 3.16)
find_program(CCACHE_FOUND ccache)
if(CCACHE_FOUND)
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache)
set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache)
endif(CCACHE_FOUND)
project(smite)
option(NOIR_BUILD_TESTS "Build tests" ON)
option(NOIR_UNITY_BUILD "Enable unity build" OFF)
option(USE_CONAN "Use conan to setup build dependencies" ON)
option(CHECK_CONNECTION "Check the network connection status" ON)
if(NOIR_BUILD_TESTS)
include(CTest)
include(libs/cmake/Catch2/Catch.cmake)
endif()
set(CMAKE_CXX_STANDARD 20)
add_compile_definitions(BOOST_ASIO_HAS_STD_INVOKE_RESULT)
include(cmake_common.txt)
compiler_minimum_required("GNU" 11.0)
compiler_minimum_required("Clang" 10.0)
compiler_minimum_required("AppleClang" 10.0)
setup_conan()
setup_macos_path()
set(Boost_USE_STATIC_LIBS ON)
find_package(Catch2)
find_package(Boost REQUIRED)
find_package(cppcodec REQUIRED)
find_package(fmt REQUIRED)
find_package(libb2 REQUIRED)
find_package(libpqxx REQUIRED)
find_package(OpenSSL 3 REQUIRED)
find_package(Protobuf REQUIRED)
find_package(RocksDB REQUIRED)
find_package(scope-lite REQUIRED)
find_package(spdlog REQUIRED)
find_package(xxHash REQUIRED)
find_package(date REQUIRED)
add_subdirectory(libs)
add_subdirectory(src)
add_subdirectory(proto)
add_subdirectory(cmd)