Skip to content

Commit c487fb1

Browse files
committed
fix: restore dconfig_meta_files macro for DTK5 compatibility
1. Reverted the conditional logic in dtkcore.cmake to install DtkDConfigMacros.cmake for DTK5 builds 2. The macro `dconfig_meta_files` was removed in DTK6 but is still required for DTK5 compatibility 3. Changed condition from `if (NOT DTK5)` to `if (DTK5)` to ensure the deprecated macro file is installed when building for DTK5 4. This preserves backward compatibility for projects that rely on the `dconfig_meta_files` function in DTK5 environments Log: Restored compatibility with DTK5 projects using dconfig_meta_files macro Influence: 1. Test building with DTK5 enabled to verify DtkDConfigMacros.cmake is installed 2. Verify that the `dconfig_meta_files` function is available in DTK5 builds 3. Test building with DTK6 to ensure the deprecated macro is not installed 4. Check that existing DTK5 projects can successfully use the dconfig_meta_files macro 5. Verify CMake installation paths contain the correct macro files for each DTK version fix: 恢复 dconfig_meta_files 宏以支持 DTK5 兼容性 1. 在 dtkcore.cmake 中恢复条件逻辑,为 DTK5 构建安装 DtkDConfigMacros.cmake 2. `dconfig_meta_files` 宏在 DTK6 中被移除,但在 DTK5 环境中仍然需要 3. 将条件从 `if (NOT DTK5)` 改为 `if (DTK5)`,确保在构建 DTK5 时安装已弃 用的宏文件 4. 这为依赖 DTK5 环境中 `dconfig_meta_files` 函数的项目保留了向后兼容性 Log: 恢复与使用 dconfig_meta_files 宏的 DTK5 项目的兼容性 Influence: 1. 测试启用 DTK5 的构建,验证 DtkDConfigMacros.cmake 是否正确安装 2. 验证 `dconfig_meta_files` 函数在 DTK5 构建中是否可用 3. 测试使用 DTK6 构建,确保不安装已弃用的宏 4. 检查现有 DTK5 项目能否成功使用 dconfig_meta_files 宏 5. 验证 CMake 安装路径是否包含适用于各 DTK 版本的正确宏文件
1 parent 9650bbc commit c487fb1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dtkcore.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ install(FILES cmake/DtkTools/DtkDBusMacros.cmake
9494
install(FILES ${CMAKE_SOURCE_DIR}/cmake/DtkTools/DtkDConfigMacros.cmake
9595
DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/Dtk${DTK_NAME_SUFFIX}Tools")
9696

97-
if (NOT DTK5)
97+
if (DTK5)
9898
set(DCONFIG_DEPRECATED_FUNCS [=[
9999
# deprecated since dtk6
100100
function(dconfig_meta_files)

0 commit comments

Comments
 (0)