已合并
fix: 完善三方依赖安装并修正文档错误 #894
liu-wei创建于 5月27日
fix: 完善三方依赖安装并修正文档错误 #894
已合并
liu-wei创建于 5月27日
liu-wei
liu-wei成员
5月27日

描述

本次修复主要完善三方依赖安装、依赖下载地址与相关文档说明,提升离线/联网构建依赖准备的一致性,并修正文档中的格式和返回码问题。

主要改动如下:

  1. install_deps.sh 中新增 pkg-config 前置检查与安装流程,并在检查 googletest 时抑制 pkg-config 缺失场景下的无效错误输出。
  2. 更新 json 三方依赖下载地址为 OBS json-3.11.3.tar.gz,同步更新 cann-cmakemaster-016 及对应 SHA256,并补充三方库下载脚本中的 cmake 包下载项。
  3. 修正 AICPU UT 公共工具头文件中 string 未限定命名空间的问题,补充 <string> 并使用 std::string
  4. 修正文档目录树、步骤编号、交付件分隔、注释错字以及 aclnn 返回码重复项等文档问题。
  5. 清理 SECURITY.md 中过期的三方依赖脚本声明,补充当前实际使用的下载脚本和 cann-cmake 来源说明。

关联的Issue

暂无关联 Issue。

测试

已完成如下验证:

  1. 执行 bash -n install_deps.sh,脚本语法检查通过。
  2. 执行 python3 -m py_compile scripts/tools/third_lib_download.py,Python 脚本语法检查通过。
  3. 使用 rg 检查旧 json 下载地址、cmake-master-014、裸 string node_def_strgcc >= 7.3.0、文档错别字及过期 cmake/third_party/json.cmake 等旧模式,均未检出。
  4. 执行 CRLF-aware git diff --check,空白字符检查通过。

未执行项:当前本地环境未安装 cmake,因此未执行 CMake 最小配置验证和 AICPU UT 编译验证。

文档更新

更新了安装、编译、开发、调用、返回码、安全声明等相关文档,主要包括:

  • 安装文档补充 gcc/g++ >= 7.3.0 依赖说明。
  • 编译文档更新 json 与 cann-cmake master-016 下载信息。
  • 开发与调用文档修正格式、步骤编号和注释错误。
  • 返回码文档修正废弃返回码项,避免与最新返回码重复。
  • 安全声明文档清理过期三方依赖脚本路径并补充当前依赖来源。

类型标签

likedislike
Pull Request已成功合入, 合并人@CANN-robot
(感谢 liu-wei 的贡献)
liu-weiliu-wei成员
5月27日 创建了 pull request,commit 53f842e6
CANN-robot
CANN-robot成员
5月27日 评论:

Thanks for your pull-request.
The full list of commands accepted by me can be found at here
You can get sig-info at here


PR Approval Progress

Congratulations! All modules have met the lgtm and approve requirements.

Module Approval Details

module lgtm status approve status
repo-cann/ops-cv 张磊, 徐鲁威 (2/2) 张磊 (1/1)

💡 Tip:

  • Committer can comment /approve or /lgtm
  • Commenting /approve implies both code review (lgtm) and intent to merge (approve)

CLA Signature Pass

liu-wei, thanks for your pull request. All authors of the commits have signed the CLA. 👍

likedislike
CANN-robotCANN-robot成员
5月27日 添加了label:cann-cla/yes
CANN-robotCANN-robot成员
5月27日 将zhou-qilong,rxtfeng,loov1,zl_hw,llimwang,gubaocheng设为评审人
CANN-robotCANN-robot成员
5月27日 将zhou-qilong,rxtfeng,loov1,zl_hw,llimwang,gubaocheng设为审查人
liu-weiliu-wei成员
5月27日 修改了pull request 的描述
liu-wei
liu-wei成员
5月27日 评论:

compile

likedislike
liu-weiliu-wei成员
5月27日 update merge request[project id: 7657293, iid: 894, commit_id: 53cd91b751432f6d6e1b7febebc2f04fed6ad1ab] virtual merging success
CANN-robotCANN-robot成员
5月27日 添加了label:ci-pipeline-running
CANN-robot
CANN-robot成员
5月27日 评论:

流水线任务触发成功
任务链接 [3fc0febacffe47579c9979408b3bada3][流水线指导]

任务名称状态日志下载链接
Compile_Ascend_X86 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_mobile_station ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_experimental ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_experimental ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_A5 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_A5 ✅ SUCCESS >>>>> >>>>>
pre_comment ✅ SUCCESS >>>>>
Compile_Pre ✅ SUCCESS >>>>>
Compile_Ascend_X86_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_mobile_station_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_experimental_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_A5_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_experimental_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_A5_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_910b ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_910c ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_950 ✅ SUCCESS >>>>> >>>>>
UT_Test ✅ SUCCESS
PreSmoke_A900 ✅ SUCCESS >>>>>
API_Check ✅ SUCCESS >>>>>
PreSmoke_ATK_Test_A2 ✅ SUCCESS >>>>>

[2026-05-27 12:36:25]    CI执行结束

likedislike
CANN-robot
CANN-robot成员
5月27日 评论:

流水线任务触发成功
任务链接 [15e92abe84d1475e8b0cf1cf18a1bd41][流水线指导]

任务名称状态日志下载链接
codecheck ✅ SUCCESS
SCA ✅ SUCCESS >>>>>
antipoison ✅ SUCCESS >>>>>
codecheck_checkpr ✅ SUCCESS
StaticCheck_codespell_check ✅ SUCCESS
StaticCheck_link_validity_check ✅ SUCCESS
StaticCheck_resource_existence_check ✅ SUCCESS
StaticCheck_tag_closed_check ✅ SUCCESS
StaticCheck_markdownlint ✅ SUCCESS
codecheck_codestyle ⚠️ WARNING >>>>>
codecheck_precommit ⚠️ WARNING >>>>> >>>>>

[2026-05-27 12:30:25]    CI执行结束

likedislike
CANN-robotCANN-robot成员
5月27日 添加了label:api-check-pass
CANN-robotCANN-robot成员
5月27日 删除了label:ci-pipeline-running
CANN-robotCANN-robot成员
5月27日 添加了label:ci-pipeline-passed
zl_hw成员
5月28日 评论:

/lgtm
/approve

likedislike
CANN-robotCANN-robot成员
5月28日 添加了label:approved
loov成员
5月28日 评论:

/lgtm

likedislike
CANN-robotCANN-robot成员
5月28日 添加了label:lgtm
CANN-robot
CANN-robot成员
5月28日 评论:

Review Guide

This pull-request passes review.
Committers who wrote a comment of /approve are: 张磊.
Reviewers who wrote a comment of /lgtm are: 张磊, 徐鲁威.

likedislike
CANN-robotCANN-robot成员
5月28日 合入了pull request