Skip to content

build: update debian package configuration for search component#283

Merged
Johnson-zs merged 1 commit intolinuxdeepin:masterfrom
liyigang1:master
Apr 29, 2026
Merged

build: update debian package configuration for search component#283
Johnson-zs merged 1 commit intolinuxdeepin:masterfrom
liyigang1:master

Conversation

@liyigang1
Copy link
Copy Markdown
Contributor

Added libdfm-search and libdfm-search-dev directories to .gitignore
Updated libdfm-search.install to replace dfm-search-client with dfm-searcher
Changed binary installation path from /usr/libexec to /usr/bin
Fixed missing newline at end of install file

This change aligns the package configuration with the current binary naming
and location conventions. The search client binary has been renamed and
relocated to the standard /usr/bin directory.

The change maintains package installation correctness while updating paths
to match current build output

Influence:

  1. Verify debian package builds without errors
  2. Check that dfm-searcher binary is correctly installed to /usr/bin
  3. Ensure .gitignore properly excludes generated debian directories
  4. Confirm package dependencies are still satisfied

build: 更新搜索组件的 debian 打包配置

在 .gitignore 中添加了 libdfm-search 和 libdfm-search-dev 目录
更新 libdfm-search.install,将 dfm-search-client 替换为 dfm-searcher
将二进制文件安装路径从 /usr/libexec 更改为 /usr/bin
修复了安装文件末尾缺少换行符的问题

此变更使打包配置与当前二进制命名和位置约定保持一致
搜索客户端二进制文件已重命名并重新定位到标准的 /usr/bin 目录

该变更在保持打包正确性的同时更新路径以匹配当前构建输出

Influence:

  1. 验证 debian 包构建无错误
  2. 检查 dfm-searcher 二进制文件是否正确安装到 /usr/bin
  3. 确保 .gitignore 正确排除生成的 debian 目录
  4. 确认包依赖关系仍然满足

  Added libdfm-search and libdfm-search-dev directories to .gitignore
  Updated libdfm-search.install to replace dfm-search-client with dfm-searcher
  Changed binary installation path from /usr/libexec to /usr/bin
  Fixed missing newline at end of install file

  This change aligns the package configuration with the current binary naming
  and location conventions. The search client binary has been renamed and
  relocated to the standard /usr/bin directory.

  The change maintains package installation correctness while updating paths
  to match current build output

  Influence:
  1. Verify debian package builds without errors
  2. Check that dfm-searcher binary is correctly installed to /usr/bin
  3. Ensure .gitignore properly excludes generated debian directories
  4. Confirm package dependencies are still satisfied

  build: 更新搜索组件的 debian 打包配置

  在 .gitignore 中添加了 libdfm-search 和 libdfm-search-dev 目录
  更新 libdfm-search.install,将 dfm-search-client 替换为 dfm-searcher
  将二进制文件安装路径从 /usr/libexec 更改为 /usr/bin
  修复了安装文件末尾缺少换行符的问题

  此变更使打包配置与当前二进制命名和位置约定保持一致
  搜索客户端二进制文件已重命名并重新定位到标准的 /usr/bin 目录

  该变更在保持打包正确性的同时更新路径以匹配当前构建输出

  Influence:
  1. 验证 debian 包构建无错误
  2. 检查 dfm-searcher 二进制文件是否正确安装到 /usr/bin
  3. 确保 .gitignore 正确排除生成的 debian 目录
  4. 确认包依赖关系仍然满足
@github-actions
Copy link
Copy Markdown

  • 检测到debian目录文件有变更: debian/libdfm-search.install

@deepin-ci-robot
Copy link
Copy Markdown

deepin pr auto review

这段代码变更主要是关于 Debian 打包配置的修改,涉及 .gitignore 文件和安装规则文件。以下是对这些变更的详细审查和改进意见:

1. 变更内容概述

  1. .gitignore 变更

    • 新增了忽略规则:debian/libdfm-search-dev/*debian/libdfm-search/*
    • 目的:防止构建过程中生成的 debian/libdfm-searchdebian/libdfm-search-dev 目录被意外提交到 Git 仓库中。
  2. debian/libdfm-search.install 变更

    • 库文件路径:保持不变,依然是 usr/lib/*/libdfm-search*.so*,用于安装动态链接库。
    • 可执行文件路径
      • 旧路径:usr/libexec/dfm-search-client
      • 新路径:usr/bin/dfm-searcher
    • 这意味着该组件的可执行文件安装位置从 libexec 变更为 bin,且文件名发生了变化。

2. 审查意见

A. 语法逻辑

  • .gitignore:语法正确。使用 * 通配符匹配目录下的所有内容是标准做法。
  • .install 文件:Debian 安装文件语法正确。路径前没有 /,表示相对于构建根目录的路径。

B. 代码质量

  • 文件结尾换行
    • debian/libdfm-search.install 文件的最后一行(usr/bin/dfm-searcher)标记为 \ No newline at end of file
    • 改进建议:建议在文件末尾添加一个换行符。虽然大多数构建工具能容忍这种情况,但 POSIX 标准建议文本文件应以换行符结束,这能避免某些脚本或工具在读取最后一行时出现问题。

C. 代码性能

  • 此处不涉及运行时代码,主要是构建配置。对构建性能无直接影响。

D. 代码安全

  • 可执行文件位置变更 (libexec -> bin)
    • 旧位置 (usr/libexec):通常用于存放系统内部调用的辅助程序,通常不在用户的 PATH 环境变量中,或者优先级较低。这有助于减少直接暴露给用户的攻击面。
    • 新位置 (usr/bin):这是标准的用户可执行文件目录,所有用户都可以直接调用。
    • 安全建议
      1. 确认 dfm-searcher 是否是设计给用户直接在命令行调用的工具。如果是,放在 usr/bin 是合适的。
      2. 如果 dfm-searcher 主要是作为后台服务或仅供其他程序内部调用的客户端,建议保留在 usr/libexecusr/lib/dfm-search(如果遵循 FHS 的某些变体),或者确保其权限设置得当,避免不必要的权限提升风险。
      3. 如果这是一个守护进程或服务,请确保相应的 systemd 服务文件或 init.d 脚本中的路径已经同步更新为 /usr/bin/dfm-searcher,否则服务将启动失败。

3. 总结与改进建议

  1. 修复文件结尾:在 debian/libdfm-search.install 文件末尾补全换行符。
  2. 路径一致性检查:请全面检查项目中其他配置文件(如 debian/rules, systemd 单元文件, dbus 配置文件, desktop 文件等),确保所有引用该可执行文件的路径都已从 /usr/libexec/dfm-search-client 更新为 /usr/bin/dfm-searcher
  3. 安全审查:确认将二进制文件移至 /usr/bin 的意图。如果它是一个守护进程,确保它不会以不必要的高权限运行,且其配置文件权限安全。

修正后的 debian/libdfm-search.install 建议内容:

 usr/lib/*/libdfm-search*.so*
-usr/bin/dfm-searcher
\ No newline at end of file
+usr/bin/dfm-searcher
+

@deepin-ci-robot
Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: Johnson-zs, liyigang1

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

@Johnson-zs Johnson-zs merged commit 0203e8c into linuxdeepin:master Apr 29, 2026
17 of 19 checks passed
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.

3 participants