1 Star 0 Fork 1

小风code/SkyGameEngine3D

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
CMakeLists.txt 2.29 KB
一键复制 编辑 原始数据 按行查看 历史
小风code 提交于 2023-09-12 00:28 . 增加模板文件
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)
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C++
1
https://gitee.com/xfcode/sky-game-engine3-d.git
git@gitee.com:xfcode/sky-game-engine3-d.git
xfcode
sky-game-engine3-d
SkyGameEngine3D
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385