Bug 4224 - [Anolis OS 23] 使用5.10.134-13.2_alpha1.an23.aarch64 的kernel构建 arm 的 kmod 失败
Summary: [Anolis OS 23] 使用5.10.134-13.2_alpha1.an23.aarch64 的kernel构建 arm 的 kmod 失败
Status: RESOLVED FIXED
Alias: None
Product: Anolis OS 23
Classification: Anolis OS
Component: BaseOS Packages (show other bugs) BaseOS Packages
Version: 23.0
Hardware: All Linux
: P3-Medium S3-normal
Target Milestone: ---
Assignee: xuchunmei
QA Contact: bolong_tbl
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-02-24 16:32 UTC by happy_orange
Modified: 2023-05-04 10:31 UTC (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description happy_orange alibaba_cloud_group 2023-02-24 16:32:14 UTC
Description of problem:
使用5.10.134-13.2_alpha1.an23.aarch64 的kernel构建 arm 的 kmod 时,提示 build 目录为空:

构建的 kmod 包的 pr:
https://gitee.com/src-anolis-sig/kmod-rds_prefetch_tuning/pulls/4

构建错误日志:
http://build.openanolis.cn/kojifiles/work/tasks/6702/546702/build.log
错误提示:
+ make -C /lib/modules/5.10.134-13.2_alpha1.an23.aarch64/build M=/builddir/build/BUILD/rds_prefetch_tuning-1.0 modules
make: Entering directory '/builddir/build/BUILD/rds_prefetch_tuning-1.0'
make: Leaving directory '/builddir/build/BUILD/rds_prefetch_tuning-1.0'
make: *** /lib/modules/5.10.134-13.2_alpha1.an23.aarch64/build: No such file or directory.  Stop.

经过定位发现:
build 为一个空的路径,软连接存在错误。
build -> ../../../usr/src/kernels/5.10.134-13.2_alpha1.an23.aarch64

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. rpmbuild -ba kmod-rds_prefetch_tuning
2.
3.

Actual results:
++ pwd
+ make -C /lib/modules/5.10.134-13.2_alpha1.an23.aarch64/build M=/builddir/build/BUILD/rds_prefetch_tuning-1.0 modules
make: Entering directory '/builddir/build/BUILD/rds_prefetch_tuning-1.0'
make: Leaving directory '/builddir/build/BUILD/rds_prefetch_tuning-1.0'
make: *** /lib/modules/5.10.134-13.2_alpha1.an23.aarch64/build: No such file or directory.  Stop.
error: Bad exit status from /var/tmp/rpm-tmp.gCUxkC (%build)


Expected results:
构建成功,生成 rpm 


Additional info:
Comment 1 xuchunmei alibaba_cloud_group 2023-02-24 18:25:10 UTC
system-rpm-config里面添加了软连接处理,将绝对路径换成了相对路径导致的问题。
已回退:https://gitee.com/src-anolis-os/system-rpm-config/pulls/32

内核需要rebuild
Comment 2 xuchunmei alibaba_cloud_group 2023-05-04 10:31:43 UTC
内核已更新。