-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
50 lines (43 loc) · 1.68 KB
/
Copy pathCMakeLists.txt
File metadata and controls
50 lines (43 loc) · 1.68 KB
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
cmake_minimum_required(VERSION 3.10)
project("libGTFOklahoma")
set(CMAKE_CXX_STANDARD 17)
include(GNUInstallDirs)
find_package(Threads REQUIRED)
option(BUILD_SAMPLE_CLIENT "Build the sample client and its dependencies" ON)
# 3P Includes
set(3P_DIR ${CMAKE_SOURCE_DIR}/third_party)
set(CATCH_INCLUDE_DIR ${3P_DIR}/Catch2/single_include)
set(FAKEIT_INCLUDE_DIR ${3P_DIR}/FakeIt/single_header)
set(RAPID_JSON_INCLUDE_DIR ${3P_DIR}/rapidjson/include)
set(SPDLOG_INCLUDE_DIR ${3P_DIR}/spdlog/include)
set(SQLITE_ORM_INCLUDE_DIR ${3P_DIR}/sqlite_orm/include)
# Local includes
set(GAMEDATA_DIR ${CMAKE_SOURCE_DIR}/data)
set(LIBGTFOKLAHOMA_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/include)
# libgtfoklahoma
set(LIBGTFOKLAHOMA_SOURCES
${CMAKE_SOURCE_DIR}/src/action_model.cpp
${CMAKE_SOURCE_DIR}/src/actions.cpp
${CMAKE_SOURCE_DIR}/src/ending_model.cpp
${CMAKE_SOURCE_DIR}/src/endings.cpp
${CMAKE_SOURCE_DIR}/src/engine.cpp
${CMAKE_SOURCE_DIR}/src/event_model.cpp
${CMAKE_SOURCE_DIR}/src/events.cpp
${CMAKE_SOURCE_DIR}/src/game.cpp
${CMAKE_SOURCE_DIR}/src/issue_model.cpp
${CMAKE_SOURCE_DIR}/src/issues.cpp
${CMAKE_SOURCE_DIR}/src/item_model.cpp
${CMAKE_SOURCE_DIR}/src/items.cpp
${CMAKE_SOURCE_DIR}/src/rules.cpp
${CMAKE_SOURCE_DIR}/src/stat_model.cpp
${CMAKE_SOURCE_DIR}/src/stats.cpp)
add_library(libgtfoklahoma STATIC ${LIBGTFOKLAHOMA_SOURCES})
target_include_directories(libgtfoklahoma PUBLIC
${GAMEDATA_DIR}
${LIBGTFOKLAHOMA_INCLUDE_DIR}
${RAPID_JSON_INCLUDE_DIR}
${SPDLOG_INCLUDE_DIR}
${SQLITE_ORM_INCLUDE_DIR})
target_link_libraries(libgtfoklahoma Threads::Threads)
add_subdirectory(sample_client)
add_subdirectory(test)