代码拉取完成,页面将自动刷新
cmake_minimum_required (VERSION 3.23)
project("SkyGameEngine3d")
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED true)
# 引擎源码目录
set(ENGINE_SRC_DIR ${PROJECT_SOURCE_DIR}/Engine/Src)
# 引擎源码 runtime 目录
set(ENGINE_SRC_RUNTIME_DIR ${ENGINE_SRC_DIR}/Runtime)
set(ENGINE_SRC_EDITOR_DIR ${ENGINE_SRC_DIR}/Editor)
# 引擎配置目录
set(ENGINE_CONFIG_DIR ${PROJECT_SOURCE_DIR}/Engine/Config)
# 引擎输出目录
set(CMAKE_BUILD_RPATH ${PROJECT_SOURCE_DIR}/Engine/Build/Output)
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BUILD_RPATH}/Lib)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BUILD_RPATH}/Bin)
#引擎脚本目录
set(BUILD_SCRIPT_DIR ${PROJECT_SOURCE_DIR}/Script)
set(BUILD_TOOL_DIR ${BUILD_SCRIPT_DIR}/BuildTool)
set(BUILD_CMAKE_DIR ${BUILD_SCRIPT_DIR}/CMake)
include(${BUILD_CMAKE_DIR}/BuildTool.cmake)
set(ENGINE_MODULE_CONFIG_TEMPLATE ${BUILD_CMAKE_DIR}/ModuleConfig.h.in)
#引擎第三方目录
set(ENGINE_3RD ${ENGINE_SRC_DIR}/ThirdParty)
set(BUILD_SHARED_LIBS true)
if (MSVC)
add_compile_definitions(MSVC)
add_compile_definitions(UNICODE _UNICODE)
add_compile_definitions(PLATFORM_NAME=Windows)
# Windows 中有个很讨厌的 Min Max 宏定义,导致冲突
add_compile_definitions(NOMINMAX)
endif()
# Py 环境
set(PY_EXE ${PROJECT_SOURCE_DIR}/Script/Python/Evn/Scripts/python.exe)
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
add_subdirectory(${ENGINE_SRC_RUNTIME_DIR}/Core)
add_subdirectory(${ENGINE_SRC_RUNTIME_DIR}/AssetCore)
add_subdirectory(${ENGINE_SRC_RUNTIME_DIR}/App)
add_subdirectory(${ENGINE_SRC_RUNTIME_DIR}/Engine)
add_subdirectory(${ENGINE_SRC_RUNTIME_DIR}/UI)
add_subdirectory(${ENGINE_SRC_RUNTIME_DIR}/Object)
add_subdirectory(${ENGINE_SRC_RUNTIME_DIR}/Render/RenderCore)
add_subdirectory(${ENGINE_SRC_RUNTIME_DIR}/RHI/RHICore)
add_subdirectory(${ENGINE_SRC_RUNTIME_DIR}/RHI/D3D12RHI)
add_subdirectory(${ENGINE_SRC_RUNTIME_DIR}/Test)
add_subdirectory(${ENGINE_SRC_RUNTIME_DIR}/Framework)
add_subdirectory(${ENGINE_3RD}/GoogleTest)
add_subdirectory(${ENGINE_3RD}/DirectXHeaders)
add_subdirectory(${ENGINE_3RD}/DirectXTK12)
# 动态Load的库
# set(DYNAMIC_LOAD_LIB D3D12RHI)
# target_link_libraries(${PROJECT_NAME} ${DYNAMIC_LOAD_LIB})
add_subdirectory(${ENGINE_SRC_EDITOR_DIR})
#add_dependencies(${PROJECT_NAME} D3D12RHI Framework)
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。