已合并
refactor: init_cann_project() 移至 dependencies.cmake 之后调用 #8702
zhaoyingdong创建于 17 天前
refactor: init_cann_project() 移至 dependencies.cmake 之后调用 #8702
已合并
zhaoyingdong创建于 17 天前
zhaoyingdong
17 天前

描述

refactor: init_cann_project() 移至 dependencies.cmake 之后调用
add_cann_third_party()依赖init_cann_project() 中的变量,所以需要放到add_cann_third_party()前面

关联的Issue

测试

文档更新

类型标签

AI/Agent生成声明

  • [x ] AI辅助编写
likedislike
Pull Request已成功合入, 合并人@CANN-robot
(感谢 zhaoyingdong 的贡献)
Zzhaoyingdong
17 天前 创建了 pull request,commit 7864c661
atomgit-bot
atomgit-bot
17 天前 评论:

变更摘要

本次 PR 是一次构建脚本的调用顺序调整,主要修复 add_cann_third_party() 无法获取到 init_cann_project() 中定义的变量的问题。通过将 init_cann_project() 的调用从原位置移动到 dependencies.cmake 之后、add_cann_third_party() 之前,确保相关变量在依赖方调用前已完成初始化。改动仅涉及 1 个文件,新增和删除各 1 行。

主要改动

  • 调整 init_cann_project() 的调用位置: 将 init_cann_project() 的调用移动到 dependencies.cmake 之后执行,使其变量初始化时机符合依赖关系。
  • 保证 add_cann_third_party() 的前置依赖: 将 init_cann_project() 置于 add_cann_third_party() 之前调用,确保 add_cann_third_party() 能正常读取 init_cann_project() 中定义的变量。
likedislike
atomgit-bot
atomgit-bot
17 天前 评论:

代码审查

✅ 未发现问题

likedislike
CANN-robot
CANN-robot成员
17 天前 评论:

Hi @zhaoyingdong, welcome to submitting your first PR to ops-nn!

PR Merge Steps

1. CLA Signing

If the current PR label includes cann-cla/yes, it means you have signed the CLA and can proceed to the next step. If the label includes cann-cla/no, please sign the CLA first. If you have any questions, please refer to the FAQ.

2. CI Check

Please comment /compile to trigger the CI pipeline check. If the CI run is successful, the PR will be tagged with ci-pipeline-passed and you can proceed to the next step. If the CI run fails, the PR will be tagged with ci-pipeline-failed, please check the CI logs to fix the issues in the PR. If you have any questions, please refer to the FAQ.

3. Code Review

After CI passes, please refer to the PR Approval Progress and proactively @ the committers in the table to review the code. After approval, committers will comment /lgtm and /approve. Once the lgtm and approved labels are successfully added, the PR will be merged automatically.

likedislike
CANN-robotCANN-robot成员
17 天前 添加了label:cann-cla/yes
CANN-robot
CANN-robot成员
17 天前 评论:

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-nn 杨阳, 刘波 (2/2) 杨阳, 刘波 (2/1)

💡 Tip:

  • Committer can comment /approve or /lgtm
  • Commenting /approve implies both code review (lgtm) and intent to merge (approve)
likedislike
CANN-robot
CANN-robot成员
17 天前 评论:

CLA Signature Pass

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

likedislike
CANN-robotCANN-robot成员
17 天前 将zengjuan,chaotang233,crystalhu,yangyang016,fanqirui,chenqi317,liubo75,tangweiwei2,pingchuantang设为评审人
CANN-robotCANN-robot成员
17 天前 将zengjuan,chaotang233,crystalhu,yangyang016,fanqirui,chenqi317,liubo75,tangweiwei2,pingchuantang设为审查人
zhaoyingdong
17 天前 评论:

/compile

likedislike
Zzhaoyingdong
17 天前 update merge request[project id: 7665709, iid: 8702, commit_id: de07ba4c09b6f8c31ae1b1f2b0eb5cfdde583be5] virtual merging success
CANN-robotCANN-robot成员
17 天前 添加了label:ci-pipeline-running
CANN-robot
CANN-robot成员
17 天前 评论:

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

任务名称状态日志下载链接
Compile_Ascend_X86_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_mobile_station ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_single ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_experimental ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_950 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_950 ✅ SUCCESS >>>>> >>>>>
Compile_Pre ✅ SUCCESS >>>>>
pre_comment ✅ SUCCESS >>>>>
Compile_Ascend_X86 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_mobile_station_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_950_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_single_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_experimental_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_950_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_910b ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_910c ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_950 ✅ SUCCESS >>>>> >>>>>
Compile_classify ✅ SUCCESS >>>>>
Compile_Ascend_X86_mobile_station_9030_ubuntu24 ✅ SUCCESS >>>>> >>>>>
UT_Test_ophost ✅ SUCCESS
UT_Test_opapi ✅ SUCCESS
UT_Test_kernel ✅ SUCCESS
UT_Test_opgraph ✅ SUCCESS
PreSmoke_A900 ✅ SUCCESS >>>>>
API_Check ✅ SUCCESS >>>>>
PreSmoke_ATK_Test_A2 ✅ SUCCESS >>>>>
UT_Test_report_lcov ⚠️ WARNING >>>>>

[2026-08-14 13:35:27]    CI执行结束

likedislike
CANN-robot
CANN-robot成员
17 天前 评论:

流水线任务触发成功
任务链接 [9aa2847932b646cbbbfbf63b55019b2b][流水线指导]

任务名称状态日志下载链接
antipoison ✅ SUCCESS >>>>>
codecheck_checkpr ✅ SUCCESS
StaticCheck_codespell ✅ SUCCESS
StaticCheck_link_validity ✅ SUCCESS
StaticCheck_resource_existence ✅ SUCCESS
StaticCheck_tag_closed ✅ SUCCESS
StaticCheck_markdownlint ✅ SUCCESS
codecheck_precommit ✅ SUCCESS >>>>>
SCA ✅ SUCCESS >>>>>

[2026-08-14 13:19:18]    CI执行结束

likedislike
CANN-robotCANN-robot成员
17 天前 添加了label:api-check-pass
CANN-robotCANN-robot成员
17 天前 删除了label:ci-pipeline-running
CANN-robotCANN-robot成员
17 天前 添加了label:ci-pipeline-passed
yangyang016成员
16 天前 评论:

/lgtm
/approve

likedislike
CANN-robotCANN-robot成员
16 天前 添加了label:approved
liubo75成员
16 天前 评论:

/lgtm
/approve

likedislike
CANN-robotCANN-robot成员
16 天前 添加了label:lgtm
CANN-robotCANN-robot成员
16 天前 合入了pull request