-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
67 lines (50 loc) · 1.44 KB
/
CMakeLists.txt
File metadata and controls
67 lines (50 loc) · 1.44 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
cmake_minimum_required(VERSION 3.28)
include(cmake/prelude.cmake)
include(cmake/project-is-top-level.cmake)
include(cmake/variables.cmake)
include(cmake/reflection.cmake)
include(cmake/gather_shared_sources.cmake)
include(cmake/ignore_list.cmake)
include(cmake/unity-build.cmake)
#set(CMAKE_BUILD_PARALLEL_LEVEL, 4)
#set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS, "ON")
#set(GLARE_BUILD_SHARED, "OFF")
if(GLARE_USE_CLANGCL)
set(CMAKE_GENERATOR_TOOLSET "ClangCL")
endif()
project(
glare
VERSION 0.2.0
DESCRIPTION "Glare - Open Source Game Engine"
HOMEPAGE_URL "https://github.com/ImmutableOctet/glare"
LANGUAGES CXX
)
# TODO: Revisit when we start using C++20 modules.
# Disabled for now.
set(CMAKE_CXX_SCAN_FOR_MODULES OFF)
#if($<CONFIG:Debug>)
if (MSVC)
add_compile_options(/ZI)
add_link_options(/DEBUG:FASTLINK /INCREMENTAL)
endif()
add_compile_definitions(GLARE_DEBUG=1)
#endif()
# Glare Engine source code.
# TODO: Remove to `src`, rather than `glare/src` subdirectory.
add_subdirectory("glare/src")
# ---- Post-build operations ----
include(cmake/post-build.cmake)
# ---- Install rules ----
#if(NOT CMAKE_SKIP_INSTALL_RULES)
# include(cmake/install-rules.cmake)
#endif()
# ---- Developer mode ----
if(NOT glare_DEVELOPER_MODE)
return()
elseif(NOT PROJECT_IS_TOP_LEVEL)
message(
AUTHOR_WARNING
"Developer mode is intended for developers of glare"
)
endif()
include(cmake/dev-mode.cmake)