fix: alot of stuff changed. Mostly bugfixxes / architechture changes

This commit is contained in:
2026-08-09 02:24:17 +02:00
parent 4b6f773c0c
commit 05384debbf
98 changed files with 5461 additions and 1751 deletions
+34 -2
View File
@@ -2,6 +2,24 @@ cmake_minimum_required(VERSION 3.31)
project(Destrum)
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)
include(CTest)
option(DESTRUM_ENABLE_WARNINGS "Enable warnings for first-party targets" ON)
function(destrum_enable_warnings target)
if (NOT DESTRUM_ENABLE_WARNINGS)
return()
endif()
if (MSVC)
target_compile_options(${target} PRIVATE /W4 /permissive-)
elseif (CMAKE_CXX_COMPILER_ID MATCHES "Clang|GNU")
target_compile_options(${target} PRIVATE -Wall -Wextra -Wpedantic)
endif()
endfunction()
if (MSVC)
# Disable Just My Code debugging
@@ -12,8 +30,18 @@ add_subdirectory(destrum)
add_subdirectory(lightkeeper)
add_subdirectory(TheChef)
add_custom_target(CleanupAssets)
add_dependencies(CleanupAssets
if (TARGET _internal_validate_engine_shaders)
add_custom_target(ValidateShaders)
add_dependencies(ValidateShaders _internal_validate_engine_shaders)
endif()
destrum_enable_warnings(destrum)
destrum_enable_warnings(lightkeeper)
add_custom_target(CleanupAssets
COMMAND ${CMAKE_COMMAND} -E rm -rf "$<TARGET_FILE_DIR:lightkeeper>/assets/game"
COMMAND ${CMAKE_COMMAND} -E rm -rf "$<TARGET_FILE_DIR:lightkeeper>/assets/engine"
DEPENDS
_internal_clean_game_assets
_internal_clean_engine_assets
)
@@ -40,3 +68,7 @@ if (ENABLE_SANITIZERS AND CMAKE_CXX_COMPILER_ID MATCHES "Clang|GNU")
)
endforeach()
endif()
if (BUILD_TESTING)
add_subdirectory(tests)
endif()