[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20240616170516.502261-1-masahiroy@kernel.org>
Date: Mon, 17 Jun 2024 02:05:13 +0900
From: Masahiro Yamada <masahiroy@...nel.org>
To: linux-kbuild@...r.kernel.org
Cc: linux-kernel@...r.kernel.org,
Masahiro Yamada <masahiroy@...nel.org>,
Nathan Chancellor <nathan@...nel.org>,
Nicolas Schier <nicolas@...sle.eu>
Subject: [PATCH] kbuild: rpm-pkg: fix build error with CONFIG_MODULES=n
When CONFIG_MODULES is disabled, 'make (bin)rpm-pkg' fails.
$ make allnoconfig binrpm-pkg
[ snip ]
error: File not found: .../linux/rpmbuild/BUILDROOT/kernel-6.10.0_rc3-1.i386/lib/modules/6.10.0-rc3/kernel
error: File not found: .../linux/rpmbuild/BUILDROOT/kernel-6.10.0_rc3-1.i386/lib/modules/6.10.0-rc3/modules.order
Fixes: 615b3a3d2d41 ("kbuild: rpm-pkg: do not include depmod-generated files")
Signed-off-by: Masahiro Yamada <masahiroy@...nel.org>
---
scripts/package/kernel.spec | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/scripts/package/kernel.spec b/scripts/package/kernel.spec
index 19e458341f45..f1c7a5ea338f 100644
--- a/scripts/package/kernel.spec
+++ b/scripts/package/kernel.spec
@@ -70,13 +70,11 @@ ln -fns /usr/src/kernels/%{KERNELRELEASE} %{buildroot}/lib/modules/%{KERNELRELEA
%endif
{
- for x in System.map config kernel modules.builtin \
- modules.builtin.modinfo modules.order vmlinuz; do
- echo "/lib/modules/%{KERNELRELEASE}/${x}"
- done
+ echo "/lib/modules/%{KERNELRELEASE}"
for x in alias alias.bin builtin.alias.bin builtin.bin dep dep.bin \
devname softdep symbols symbols.bin; do
+ rm -f "%{buildroot}/lib/modules/%{KERNELRELEASE}/modules.${x}"
echo "%ghost /lib/modules/%{KERNELRELEASE}/modules.${x}"
done
--
2.43.0
Powered by blists - more mailing lists