Merged
refactor(package): 排除7个aicpu公共头在pkg_inc/aicpu_common下的重复安装 #829
liu-weiAdd on Sep 8
refactor(package): 排除7个aicpu公共头在pkg_inc/aicpu_common下的重复安装 #829
Merged
Pull Request has been successfully merged by CANN-robot.
(Thank you for liu-wei's contribution.)atomgit-bot
Sep 8 Comments:
Sep 8 Comments:
变更摘要
本 PR 旨在排除 7 个 aicpu 公共头文件在 pkg_inc/aicpu_common 下的重复安装。修改集中在 cmake/package.cmake:其中 include/op_common/aicpu_common 目录原本会被整体安装到 ${CMAKE_SYSTEM_PROCESSOR}-linux/pkg_inc/aicpu_common 目标路径,而其中 7 个公共头已由 aicpu_headers_src 规则扁平安装到 include/aicpu/,因此在本次安装规则中新增 PATTERN ... EXCLUDE 过滤,避免同一头文件被重复打包。
主要改动
- 新增排除注释: 在
install(DIRECTORY ...)规则前补充注释,说明这 7 个公共头已由aicpu_headers_src规则安装至include/aicpu/,此处排除以避免重复。 - 排除
cpu_kernel.h等头文件安装: 为aicpu_common_public的目录安装规则新增 7 条PATTERN ... EXCLUDE过滤,排除cpu_attr_value.h、cpu_tensor.h、cpu_tensor_shape.h、cpu_context.h、cpu_types.h、cpu_kernel.h、cpu_kernel_register.h。 - 保持目标路径与下游行为不变: 排除仅针对已重复交付的头文件,装包时其余头文件仍合并安装到同一目标路径
pkg_inc/aicpu_common,对下游保持兼容。


Incorrect?
atomgit-bot
Sep 8 Comments:
Sep 8 Comments:
Sep 8 Added label: cann-cla/yes
CANN-robot
Sep 8 Comments:
Sep 8 Comments:
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.
You can self-configure the PR merge rules for this repository. For more details, please refer to Here.
For more, you also can visit HICANN.
PR Approval Progress
✅ Congratulations! All modules have met the lgtm and approve requirements.
Module Approval Details
| module | lgtm status | approve status |
|---|---|---|
| repo-cann/opbase | ✅ 王瑞, 宋恺 (2/2) | ✅ 王瑞, 宋恺 (2/1) |
💡 Tip:
- Committer can comment
/approveor/lgtm- Commenting
/approveimplies 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. 👍


59 messages are collapsed here。 See more
Sep 15 Added label: approved
songkai111
Sep 15 Comments:
Sep 15 Comments:
/approve


Sep 15 Added label: lgtm
Sep 15 Closed associated issue
Sep 15 Merged pull request
描述
cmake/package.cmake 中 include/op_common/aicpu_common/ 下的 7 个公共头文件被同时安装到 include/aicpu/ 和 pkg_inc/aicpu_common/context/{common,cpu_proto}/ 两个路径,产生重复副本。本 PR 在整目录安装规则中新增 PATTERN ... EXCLUDE 排除这 7 个文件,仅保留 include/aicpu/ 一份。
关联的Issue
https://gitcode.com/cann/opbase/issues/419
测试