From 4440154fc3e7da5107a7db27b01db06f7a535269 Mon Sep 17 00:00:00 2001 From: Ben Cressey Date: Tue, 1 Oct 2024 21:30:04 +0000 Subject: [PATCH] kernel-6.1: exclude more object files from devel Now that an unpacked set of kernel-devel files is present in the buildroot, object files will be found by the `/usr/lib/rpm/brp-strip` invocation that tries to ensure all files are stripped. This can lead to build failures if the host and target arch don't match, and if the target arch requires a host tool to be built. The object files will be built for the host, and the target's `strip` command will not recognize the format. In any case, these object files shouldn't be included, as they may need to be rebuilt to match the running host architecture at the time the kernel-devel files are used. Fixes: 76af8bef ("kernel-6.1: also provide uncompressed devel files") Signed-off-by: Ben Cressey --- packages/kernel-6.1/kernel-6.1.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/kernel-6.1/kernel-6.1.spec b/packages/kernel-6.1/kernel-6.1.spec index 9a115c953..ebcc43fc8 100644 --- a/packages/kernel-6.1/kernel-6.1.spec +++ b/packages/kernel-6.1/kernel-6.1.spec @@ -236,20 +236,20 @@ chmod 600 System.map \( -name module.lds -o -name vmlinux.lds.S -o -name Platform -o -name \*.tbl \) \ -print - find arch/%{_cross_karch}/{include,lib}/ -type f ! -name \*.o ! -name \*.o.d -print + find arch/%{_cross_karch}/{include,lib}/ -type f ! -name \*.o ! -name \*.o.d ! -name \*.a -print echo arch/%{_cross_karch}/kernel/asm-offsets.s echo lib/vdso/gettimeofday.c for d in \ arch/%{_cross_karch}/tools \ arch/%{_cross_karch}/kernel/vdso ; do - [ -d "${d}" ] && find "${d}/" -type f -print + [ -d "${d}" ] && find "${d}/" -type f ! -name \*.o -print done find include -type f -print find scripts -type f ! -name \*.l ! -name \*.y ! -name \*.o -print - find tools/{arch/%{_cross_karch},include,objtool,scripts}/ -type f ! -name \*.o -print + find tools/{arch/%{_cross_karch},include,objtool,scripts}/ -type f ! -name \*.o ! -name \*.a -print echo tools/build/fixdep.c find tools/lib/subcmd -type f -print find tools/lib/{ctype,hweight,rbtree,string,str_error_r}.c