-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
90 lines (82 loc) · 3.43 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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
cmake_minimum_required(VERSION 3.13) # CMake version check
set(PROJECT_NAME arcade)
project(${PROJECT_NAME}) # Create project "arcade"
set(CMAKE_CXX_STANDARD 20) # Enable c++14 standard
# add compilation flags to access dynamic library
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -fno-gnu-unique -ldl")
set(INCLUDES
sharedArchitecture/include/Api.hpp
sharedArchitecture/include/Arcade/ArcadeStruct.hpp
sharedArchitecture/include/Arcade/Core/ICore.hpp
sharedArchitecture/include/Arcade/Game/IGameModule.hpp
sharedArchitecture/include/Arcade/Graph/IDisplayModule.hpp
sharedArchitecture/include/Arcade/ECS/IComponent.hpp
sharedArchitecture/include/Arcade/ECS/IEntity.hpp
sharedArchitecture/include/Arcade/ECS/IEntityManager.hpp
sharedArchitecture/include/Arcade/ECS/IEventManager.hpp
sharedArchitecture/include/Arcade/ECS/ISystemManager.hpp
sharedArchitecture/include/Arcade/Graph/GraphStruct.hpp
sharedArchitecture/include/Arcade/Graph/IMusic.hpp
sharedArchitecture/include/Arcade/Graph/ISprite.hpp
sharedArchitecture/include/Arcade/Graph/IText.hpp
sharedArchitecture/include/Arcade/Graph/IDisplayModule.hpp
sharedArchitecture/include/Arcade/Game/IScene.hpp
)
# Add main.cpp file of project root directory as source file
set(EXEC_SRC
src/main.cpp
src/Library/DisplayHandler.hpp
src/Library/DisplayHandler.cpp
src/Library/GameHandler.hpp
src/Library/GameHandler.cpp
src/Library/LibraryFinder.cpp
src/Library/LibraryFinder.hpp
src/Core/Core.cpp
src/Core/Core.hpp
src/Game/AGameModule.hpp
src/Game/AGameModule.cpp
src/Game/AScene.hpp
src/Game/AScene.cpp
src/ECS/EventManager.cpp
src/ECS/EventManager.hpp
src/ECS/SystemManager.cpp
src/ECS/SystemManager.hpp
src/ECS/EntityManager.cpp
src/ECS/EntityManager.hpp
src/ECS/Entity.cpp
src/ECS/Entity.hpp
src/ECS/Component.cpp
src/Core/Clock.cpp
src/Core/Clock.hpp)
include_directories(src)
include_directories(src/Core)
include_directories(src/Core/MainMenu)
include_directories(src/Core/MainMenu/Components)
include_directories(src/Core/MainMenu/Systems)
include_directories(src/Core/MainMenu/Scene)
include_directories(src/ECS)
include_directories(src/Game)
include_directories(src/Library)
include_directories(sharedArchitecture/include)
include_directories(sharedArchitecture/include/Arcade)
include_directories(sharedArchitecture/include/Arcade/Core)
include_directories(sharedArchitecture/include/Arcade/ECS)
include_directories(sharedArchitecture/include/Arcade/Game)
include_directories(sharedArchitecture/include/Arcade/Graph)
# Add the SFML library to the project, uncomment the 2 line under
# if you want to use SFML:
#find_package(SFML 2.5 COMPONENTS graphics audio REQUIRED)
#add_executable(${PROJECT_NAME} ${SRC_FILES})
# Add executable target with source files listed in SOURCE_FILES variable
#add_subdirectory(src/Graph/libs/SDL)
# Graphical libraries
# TODO : uncomment sdl
add_subdirectory(src/Graph/libs/SDL)
add_subdirectory(src/Graph/libs/SFML)
add_subdirectory(src/Graph/libs/NCurses)
# Games libraries
add_subdirectory(src/Core/MainMenu)
add_subdirectory(src/Game/libs/Snake)
add_subdirectory(src/Game/libs/Nibbler)
# Core
add_executable(${PROJECT_NAME} ${EXEC_SRC} ${INCLUDES})