Accepting request 1244633 from network:ha-clustering:Factory
OBS-URL: https://build.opensuse.org/request/show/1244633 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/drbd?expand=0&rev=116
This commit is contained in:
commit
5c0c22743c
69
boo1236927-fix-build_error_against_v6.13.patch
Normal file
69
boo1236927-fix-build_error_against_v6.13.patch
Normal file
@ -0,0 +1,69 @@
|
||||
From 7d77b1b5768253deb4e4fcc645dfe0ab4ff1a292 Mon Sep 17 00:00:00 2001
|
||||
From: Su Yue <glass.su@suse.com>
|
||||
Date: Sun, 9 Feb 2025 11:36:28 +0800
|
||||
Subject: [PATCH] fix build error against v6.13
|
||||
|
||||
The DRBD build failed on the latest kernel v6.13:
|
||||
|
||||
```
|
||||
CHK build-6.13.1-1-default/compat.patch
|
||||
LN build-6.13.1-1-default/compat.patch -> ../drbd-kernel-compat/cocci_cache/47e34234767463327c545d4b02432945/compat.patch
|
||||
set -- ./build-6.13.1-1-default/compat.patch ./build-6.13.1-1-default/compat.h; \
|
||||
test $1 -nt $2 || touch -r $1 $2
|
||||
SPLIT build-6.13.1-1-default/compat.patch
|
||||
/bin/bash: line 1: build-6.13.1-1-default/compat.patch: No such file or directory
|
||||
make[3]: *** [Kbuild:222: build-6.13.1-1-default/.ts.compat.patch] Error 1
|
||||
make[2]: *** [/usr/src/linux-6.13.1-1/Makefile:2012: .] Error 2
|
||||
```
|
||||
which is caused by upstream commit:
|
||||
|
||||
commit 13b25489b6f8bd73ed65f07928f7c27a481f1820
|
||||
Author: Masahiro Yamada <masahiroy@kernel.org>
|
||||
Date: Sun Nov 10 10:34:33 2024 +0900
|
||||
|
||||
kbuild: change working directory to external module directory with M=
|
||||
|
||||
The commit changes working directory to /usr/src/packages/BUILD/drbd-9.1.23-build/drbd-9.1.23/64kb.
|
||||
|
||||
drbd/Kbuild uses relative path for compat.patch:
|
||||
obj.build := $(obj)/$(build-dir)
|
||||
...
|
||||
compat.patch := $(obj.build)/compat.patch
|
||||
|
||||
When SPLIT is calling, it's in $(build-dir)/.patches directory, thus compat.patch is not found.
|
||||
|
||||
Fix it by adding prefix $(srcroot) to obj.build.
|
||||
This patch incorporates with make option KBUILD_ABS_SRCTREE=1.
|
||||
So the make prep should be:
|
||||
|
||||
make -j4 -C default KDIR=/usr/src/linux-obj/x86_64/default prep SPAAS=false KBUILD_ABS_SRCTREE=1
|
||||
|
||||
As Linux/Documentation/kbuild/makefiles.rst says:
|
||||
|
||||
$(srcroot)
|
||||
$(srcroot) refers to the root of the source you are building, which can be
|
||||
either the kernel source or the external modules source, depending on whether
|
||||
KBUILD_EXTMOD is set. This can be either a relative or an absolute path, but
|
||||
if KBUILD_ABS_SRCTREE=1 is set, it is always an absolute path.
|
||||
|
||||
Signed-off-by: Su Yue <glass.su@suse.com>
|
||||
---
|
||||
drbd/Kbuild | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/drbd/Kbuild b/drbd/Kbuild
|
||||
index 3e1e5681bcea..31535d2a7074 100644
|
||||
--- a/drbd/Kbuild
|
||||
+++ b/drbd/Kbuild
|
||||
@@ -18,7 +18,7 @@ else
|
||||
|
||||
SHELL := /bin/bash
|
||||
|
||||
-obj.build := $(obj)/$(build-dir)
|
||||
+obj.build := $(srcroot)/$(obj)/$(build-dir)
|
||||
PHONY += $(obj.build)
|
||||
|
||||
# we don't have an official Kbuild entry point. This is only used to generate
|
||||
--
|
||||
2.39.5 (Apple Git-154)
|
||||
|
@ -1,3 +1,10 @@
|
||||
-------------------------------------------------------------------
|
||||
Sun Feb 9 04:00:30 UTC 2025 - Glass Su <glass.su@suse.com>
|
||||
|
||||
- drbd: fix build error against kernel v6.13 (boo#1236927)
|
||||
* add patch
|
||||
+ boo1236927-fix-build_error_against_v6.13.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jan 8 07:08:00 UTC 2025 - Heming Zhao <heming.zhao@suse.com>
|
||||
|
||||
|
@ -42,6 +42,7 @@ Patch0001: 0001-drbd-Fix-memory-leak.patch
|
||||
Patch1001: bsc-1025089_fix-resync-finished-with-syncs-have-bits-set.patch
|
||||
Patch1002: suse-coccinelle.patch
|
||||
Patch1003: boo1235399-fix_the_warning_of_blk_validate_limits.patch
|
||||
Patch1004: boo1236927-fix-build_error_against_v6.13.patch
|
||||
########################
|
||||
|
||||
#https://github.com/openSUSE/rpmlint-checks/blob/master/KMPPolicyCheck.py
|
||||
@ -101,7 +102,7 @@ for flavor in %{flavors_to_build}; do
|
||||
#make coccicheck
|
||||
|
||||
# call make prep to generate drbd build dir
|
||||
make %{?_smp_mflags} -C $flavor KDIR=%{kernel_source $flavor} prep SPAAS=${SPAAS}
|
||||
make %{?_smp_mflags} -C $flavor KDIR=%{kernel_source $flavor} prep SPAAS=${SPAAS} KBUILD_ABS_SRCTREE=1
|
||||
|
||||
cp -a %{_sourcedir}/Module.supported ${flavor}/build-current
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user