Skip to content

Conversation

@18202781743
Copy link
Contributor

  1. Replaced automatic DTK version detection with explicit DTK5 option
    for unified build configuration
  2. Introduced DTK_NAME_SUFFIX variable to differentiate between DTK5
    (empty) and DTK6 ("6") builds
  3. Updated all CMake configuration files to use DTK_VERSION_MAJOR and
    DTK_NAME_SUFFIX consistently
  4. Modified Debian packaging to support both DTK5 and DTK6 with separate
    build profiles
  5. Added DTK6-specific Debian package definitions and installation
    scripts
  6. Updated debian/rules to handle separate builds for DTK5 and DTK6 with
    proper version mapping
  7. Fixed include paths, library names, and configuration file names to
    follow DTK naming conventions
  8. Ensured proper Qt version selection (Qt5 for DTK5, Qt6 for DTK6)
    throughout the build system

Log: Unified build system now supports both DTK5 and DTK6 with explicit
configuration options

Influence:

  1. Test building with DTK5=ON to ensure DTK5 compatibility
  2. Test building with DTK5=OFF to ensure DTK6 compatibility
  3. Verify library naming: dtkdeclarative for DTK5, dtk6declarative for
    DTK6
  4. Check include paths: /usr/include/dtk5/ for DTK5, /usr/include/dtk6/
    for DTK6
  5. Test Debian packaging with different build profiles (nodtk5, nodtk6,
    nodoc)
  6. Verify CMake configuration files are generated with correct names
  7. Ensure QML plugin installation paths are correct for both Qt5 and Qt6
  8. Test example applications (dtk-exhibition and dtk6-exhibition)
    functionality

refactor: 统一 DTK5 和 DTK6 构建系统

  1. 将自动 DTK 版本检测改为显式 DTK5 选项,实现统一构建配置
  2. 引入 DTK_NAME_SUFFIX 变量区分 DTK5(空)和 DTK6("6")构建
  3. 更新所有 CMake 配置文件以一致使用 DTK_VERSION_MAJOR 和
    DTK_NAME_SUFFIX
  4. 修改 Debian 打包以支持 DTK5 和 DTK6 的独立构建配置
  5. 添加 DTK6 特定的 Debian 包定义和安装脚本
  6. 更新 debian/rules 以处理 DTK5 和 DTK6 的独立构建及版本映射
  7. 修复包含路径、库名称和配置文件名称以遵循 DTK 命名约定
  8. 确保整个构建系统中正确选择 Qt 版本(DTK5 用 Qt5,DTK6 用 Qt6)

Log: 统一构建系统现在支持通过显式配置选项构建 DTK5 和 DTK6

Influence:

  1. 测试使用 DTK5=ON 构建以确保 DTK5 兼容性
  2. 测试使用 DTK5=OFF 构建以确保 DTK6 兼容性
  3. 验证库命名:DTK5 为 dtkdeclarative,DTK6 为 dtk6declarative
  4. 检查包含路径:DTK5 为 /usr/include/dtk5/,DTK6 为 /usr/include/dtk6/
  5. 测试使用不同构建配置(nodtk5、nodtk6、nodoc)的 Debian 打包
  6. 验证 CMake 配置文件是否以正确名称生成
  7. 确保 QML 插件安装路径对 Qt5 和 Qt6 都正确
  8. 测试示例应用程序(dtk-exhibition 和 dtk6-exhibition)的功能

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @18202781743, you have reached your weekly rate limit of 500000 diff characters.

Please try again later or upgrade to continue using Sourcery

deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Dec 29, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#555
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Dec 30, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#555
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Dec 30, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#555
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Dec 30, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#555
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Dec 30, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#555
mhduiy
mhduiy previously approved these changes Dec 31, 2025
CMakeLists.txt Outdated
Comment on lines 18 to 21
set(EnableQt5 on)
set(EnableDtk5 on)
set(EnableQt6 off)
set(EnableDtk6 off)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这些选项现在没用了,可以删除了。

deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Dec 31, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#555
@deepin-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: 18202781743

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

1 similar comment
@deepin-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: 18202781743

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@deepin-ci-robot
Copy link
Contributor

deepin pr auto review

我来对这份 CMakeLists.txt 的修改进行审查:

  1. 语法逻辑改进:
  • 将版本控制逻辑从基于 PROJECT_VERSION_MAJOR 的判断改为使用 DTK5 选项,更直观清晰
  • 移除了重复的版本号设置,统一使用 DTK_VERSION 变量
  • 优化了版本号处理逻辑,使用 DTK_NAME_SUFFIX 来区分不同版本
  1. 代码质量改进:
  • 使用 option() 命令添加了 DTK5 选项,使构建配置更灵活
  • 统一了变量命名规范,如 DTK_VERSION_MAJOR 替代 PROJECT_VERSION_MAJOR
  • 简化了条件判断结构,减少了代码重复
  1. 代码性能改进:
  • 优化了版本号处理逻辑,减少了不必要的字符串操作
  • 简化了条件判断结构,减少了编译时的判断开销
  1. 代码安全改进:
  • 添加了更严格的版本检查,确保只有支持的版本可以构建
  • 优化了安装路径的设置,使用更明确的路径规范
  1. 建议改进:
  • 建议在设置 DTK5 选项时添加更详细的说明文档
  • 可以考虑添加对版本号的更严格验证
  • 建议在 CMakeLists.txt 开头添加项目说明注释
  • 可以考虑将版本相关的设置集中到一个单独的文件中,便于维护
  1. 其他注意事项:
  • 修改涉及大量文件,需要确保所有相关文件都正确更新
  • 需要测试不同版本的构建过程,确保没有遗漏
  • 建议添加更多的错误检查和提示信息

这些修改总体上是积极的,使代码更加清晰、可维护,但需要注意测试和文档的完善。

1. Replaced automatic DTK version detection with explicit DTK5 option
for unified build configuration
2. Introduced DTK_NAME_SUFFIX variable to differentiate between DTK5
(empty) and DTK6 ("6") builds
3. Updated all CMake configuration files to use DTK_VERSION_MAJOR and
DTK_NAME_SUFFIX consistently
4. Modified Debian packaging to support both DTK5 and DTK6 with separate
build profiles
5. Added DTK6-specific Debian package definitions and installation
scripts
6. Updated debian/rules to handle separate builds for DTK5 and DTK6 with
proper version mapping
7. Fixed include paths, library names, and configuration file names to
follow DTK naming conventions
8. Ensured proper Qt version selection (Qt5 for DTK5, Qt6 for DTK6)
throughout the build system

Log: Unified build system now supports both DTK5 and DTK6 with explicit
configuration options

Influence:
1. Test building with DTK5=ON to ensure DTK5 compatibility
2. Test building with DTK5=OFF to ensure DTK6 compatibility
3. Verify library naming: dtkdeclarative for DTK5, dtk6declarative for
DTK6
4. Check include paths: /usr/include/dtk5/ for DTK5, /usr/include/dtk6/
for DTK6
5. Test Debian packaging with different build profiles (nodtk5, nodtk6,
nodoc)
6. Verify CMake configuration files are generated with correct names
7. Ensure QML plugin installation paths are correct for both Qt5 and Qt6
8. Test example applications (dtk-exhibition and dtk6-exhibition)
functionality

refactor: 统一 DTK5 和 DTK6 构建系统

1. 将自动 DTK 版本检测改为显式 DTK5 选项,实现统一构建配置
2. 引入 DTK_NAME_SUFFIX 变量区分 DTK5(空)和 DTK6("6")构建
3. 更新所有 CMake 配置文件以一致使用 DTK_VERSION_MAJOR 和
DTK_NAME_SUFFIX
4. 修改 Debian 打包以支持 DTK5 和 DTK6 的独立构建配置
5. 添加 DTK6 特定的 Debian 包定义和安装脚本
6. 更新 debian/rules 以处理 DTK5 和 DTK6 的独立构建及版本映射
7. 修复包含路径、库名称和配置文件名称以遵循 DTK 命名约定
8. 确保整个构建系统中正确选择 Qt 版本(DTK5 用 Qt5,DTK6 用 Qt6)

Log: 统一构建系统现在支持通过显式配置选项构建 DTK5 和 DTK6

Influence:
1. 测试使用 DTK5=ON 构建以确保 DTK5 兼容性
2. 测试使用 DTK5=OFF 构建以确保 DTK6 兼容性
3. 验证库命名:DTK5 为 dtkdeclarative,DTK6 为 dtk6declarative
4. 检查包含路径:DTK5 为 /usr/include/dtk5/,DTK6 为 /usr/include/dtk6/
5. 测试使用不同构建配置(nodtk5、nodtk6、nodoc)的 Debian 打包
6. 验证 CMake 配置文件是否以正确名称生成
7. 确保 QML 插件安装路径对 Qt5 和 Qt6 都正确
8. 测试示例应用程序(dtk-exhibition 和 dtk6-exhibition)的功能
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Dec 31, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#555
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants