40 lines
1 KiB
CMake
40 lines
1 KiB
CMake
cmake_minimum_required(VERSION 3.15)
|
|
project(cntrl LANGUAGES C CXX)
|
|
|
|
set(CMAKE_C_STANDARD 11)
|
|
set(CMAKE_C_STANDARD_REQUIRED ON)
|
|
set(CMAKE_CXX_STANDARD 23)
|
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
|
|
|
if(NOT CMAKE_BUILD_TYPE)
|
|
set(CMAKE_BUILD_TYPE Release CACHE STRING "" FORCE)
|
|
endif()
|
|
|
|
# --- raylib 6.2, fetched and built from source ---
|
|
include(FetchContent)
|
|
set(BUILD_EXAMPLES OFF CACHE BOOL "" FORCE)
|
|
set(BUILD_GAMES OFF CACHE BOOL "" FORCE)
|
|
FetchContent_Declare(raylib
|
|
GIT_REPOSITORY https://github.com/raysan5/raylib.git
|
|
GIT_TAG 6.2)
|
|
FetchContent_MakeAvailable(raylib)
|
|
|
|
add_executable(cntrl
|
|
src/main.cpp
|
|
src/game/buffs.cpp
|
|
src/game/corruption.cpp
|
|
src/game/ritual.cpp
|
|
src/game/director.cpp
|
|
src/game/player.cpp
|
|
src/game/enemies.cpp
|
|
src/game/weapons.cpp
|
|
src/game/pickups.cpp
|
|
src/game/game.cpp
|
|
src/render/presenter.cpp
|
|
src/render/models.cpp
|
|
src/render/concrete.cpp
|
|
src/render/aura.cpp
|
|
src/render/ui.cpp)
|
|
|
|
target_include_directories(cntrl PRIVATE src)
|
|
target_link_libraries(cntrl PRIVATE raylib)
|