v0.1.0: 初始工程骨架 — 7模块 40头文件 32源文件 17文档 Apache-2.0

This commit is contained in:
ViewDesignEngine
2026-07-23 05:27:51 +00:00
commit 02d0520aa5
133 changed files with 5350 additions and 0 deletions
+41
View File
@@ -0,0 +1,41 @@
# Compiler settings for ViewDesignEngine
# Include with: include(cmake/CompilerSettings.cmake)
# ── GCC / Clang ───────────────────────────────────
if(CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang|AppleClang")
target_compile_options(vde_compile_options INTERFACE
-Wall -Wextra -Wpedantic
-Wshadow -Wnon-virtual-dtor
-Woverloaded-virtual -Wconversion
-Wsign-conversion -Wnull-dereference
-Wdouble-promotion -Wformat=2
)
if(ENABLE_SANITIZERS)
target_compile_options(vde_compile_options INTERFACE
-fsanitize=address,undefined -fno-omit-frame-pointer
)
target_link_options(vde_compile_options INTERFACE
-fsanitize=address,undefined
)
endif()
if(ENABLE_LTO AND CMAKE_BUILD_TYPE STREQUAL "Release")
target_compile_options(vde_compile_options INTERFACE -flto)
target_link_options(vde_compile_options INTERFACE -flto)
endif()
endif()
# ── MSVC ───────────────────────────────────────────
if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
target_compile_options(vde_compile_options INTERFACE
/W4 /permissive- /Zc:__cplusplus /utf-8
)
target_compile_definitions(vde_compile_options INTERFACE
_CRT_SECURE_NO_WARNINGS NOMINMAX
)
endif()
# ── 公共编译定义 ───────────────────────────────────
target_compile_definitions(vde_compile_options INTERFACE
VDE_VERSION_MAJOR=${PROJECT_VERSION_MAJOR}
VDE_VERSION_MINOR=${PROJECT_VERSION_MINOR}
)
+18
View File
@@ -0,0 +1,18 @@
find_package(Doxygen QUIET)
if(Doxygen_FOUND)
set(DOXYGEN_PROJECT_NAME "ViewDesignEngine")
set(DOXYGEN_PROJECT_VERSION ${PROJECT_VERSION})
set(DOXYGEN_INPUT "${CMAKE_SOURCE_DIR}/include")
set(DOXYGEN_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/docs")
set(DOXYGEN_EXTRACT_ALL YES)
set(DOXYGEN_EXTRACT_PRIVATE YES)
set(DOXYGEN_RECURSIVE YES)
set(DOXYGEN_GENERATE_HTML YES)
set(DOXYGEN_GENERATE_XML YES)
doxygen_add_docs(doc
${CMAKE_SOURCE_DIR}/include
${CMAKE_SOURCE_DIR}/docs
COMMENT "Generate API documentation"
)
endif()
+5
View File
@@ -0,0 +1,5 @@
@PACKAGE_INIT@
include("${CMAKE_CURRENT_LIST_DIR}/ViewDesignEngineTargets.cmake")
check_required_components(ViewDesignEngine)