### Basic CMake Project Setup Source: https://github.com/71darkness17/cheese-engine/blob/master/CMakeLists.txt Sets the minimum CMake version and project name with version and languages. ```cmake cmake_minimum_required(VERSION 3.28) project(CheeseEngine VERSION 1.0 LANGUAGES CXX) ``` -------------------------------- ### Doxygen Documentation Generation Setup Source: https://github.com/71darkness17/cheese-engine/blob/master/CMakeLists.txt Configures Doxygen if found, creating a custom target 'docs' to generate API documentation. ```cmake find_package(Doxygen) if(DOXYGEN_FOUND) configure_file(${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile @ONLY) add_custom_target(docs COMMAND ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMENT "Generating API documentation with Doxygen" VERBATIM ) else() message(WARNING "Doxygen not found. Documentation will not be built.") endif() ``` -------------------------------- ### Define Project Sources and Executable Source: https://github.com/71darkness17/cheese-engine/blob/master/CMakeLists.txt Lists the source files and creates the main executable for the project. ```cmake set(SOURCES src/main.cpp src/graphicCore.cc src/renderQueue.cc src/types.cpp ) add_executable(${PROJECT_NAME} ${SOURCES}) ``` -------------------------------- ### Find and Link Required Packages Source: https://github.com/71darkness17/cheese-engine/blob/master/CMakeLists.txt Finds and links necessary system packages like Vulkan and GLFW. ```cmake find_package(Vulkan REQUIRED) find_package(glfw3 3.3 REQUIRED) ``` -------------------------------- ### C++ Standard Configuration Source: https://github.com/71darkness17/cheese-engine/blob/master/CMakeLists.txt Configures the C++ standard to C++20 and ensures it's required. ```cmake set(CMAKE_CXX_STANDARD 20) set(CMAKE_CXX_STANDARD_REQUIRED ON) ``` -------------------------------- ### Set Include Directories Source: https://github.com/71darkness17/cheese-engine/blob/master/CMakeLists.txt Specifies the include directories for the project's target. ```cmake target_include_directories(${PROJECT_NAME} PUBLIC inc) ``` -------------------------------- ### Fetch External Dependencies with FetchContent Source: https://github.com/71darkness17/cheese-engine/blob/master/CMakeLists.txt Declares and makes available external C++ libraries like EnTT and GLM using FetchContent. ```cmake include(FetchContent) FetchContent_Declare( entt GIT_REPOSITORY https://github.com/skypjack/entt.git GIT_TAG v3.16.0 ) FetchContent_Declare( glm GIT_REPOSITORY https://github.com/g-truc/glm.git ) FetchContent_MakeAvailable(entt glm) ``` -------------------------------- ### Link Libraries to Executable Source: https://github.com/71darkness17/cheese-engine/blob/master/CMakeLists.txt Links the project's executable against required libraries, including Vulkan, GLFW, EnTT, and GLM. ```cmake target_link_libraries(${PROJECT_NAME} PRIVATE Vulkan::Vulkan glfw EnTT::EnTT glm::glm ) ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.