-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
57 lines (45 loc) · 1.19 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
cmake_minimum_required (VERSION 3.8)
# Enable MSVC Hot Reload
if (POLICY CMP0141)
cmake_policy(SET CMP0141 NEW)
set(CMAKE_MSVC_DEBUG_INFORMATION_FORMAT "$<IF:$<AND:$<C_COMPILER_ID:MSVC>,$<CXX_COMPILER_ID:MSVC>>,$<$<CONFIG:Debug,RelWithDebInfo>:EditAndContinue>,$<$<CONFIG:Debug,RelWithDebInfo>:ProgramDatabase>>")
endif()
if (MSVC)
set_target_properties(${BUILD_TARGET} PROPERTIES LINK_FLAGS "/PROFILE")
endif()
project ("MassiveDynamics")
# TODO make this configurable, add other platforms and whatnot
link_directories("../SDL/out/build/x64-min")
if(TRUE) # TODO make configurable
# STATIC LINKING
link_libraries(
"version.lib"
"imm32.lib"
"winmm.lib"
"setupapi.lib"
"SDL3-static.lib"
)
else()
# DYNAMIC LINKING
link_libraries(
"SDL3.lib"
)
endif()
add_executable (
MassiveDynamics
"MassiveDynamics.cpp"
"Utils/CollisionUtils.cpp"
"Utils/GeometryUtils.cpp"
"PhysicalShapes/PolygonShape.cpp"
"Collision/Separation.h"
"Collision/CollisionData.h"
"ArbiterPools.h"
)
include_directories("./"
# External dependencies
"../glm"
"../SDL/include" # Renderer only
)
if (CMAKE_VERSION VERSION_GREATER 3.12)
set_property(TARGET MassiveDynamics PROPERTY CXX_STANDARD 20)
endif()