Files
drbd/0001-drbd-build-deal-with-potentially-relative-paths-in-p.patch
heming zhao 88bb58b9c9 - drbd: fix build error against kernel v6.14 (boo#1240916)
* add patch
    + boo1240916-fix_build_error_against_kernel_v6.14.patch
  * replace suse special patch with drbd upstream fix
    - boo1236927-fix-build_error_against_v6.13.patch
    + 0001-drbd-build-deal-with-potentially-relative-paths-in-p.patch
  * remove patch, the issue is already fixed in v6.14 kernel
    - boo1235399-fix_the_warning_of_blk_validate_limits.patch

OBS-URL: https://build.opensuse.org/package/show/network:ha-clustering:Factory/drbd?expand=0&rev=158
2025-04-10 02:20:11 +00:00

51 lines
1.8 KiB
Diff

From e9d033122c939a3a522624a78bae9e4ee032c85b Mon Sep 17 00:00:00 2001
From: Lars Ellenberg <lars.ellenberg@linbit.com>
Date: Thu, 27 Feb 2025 14:07:44 +0100
Subject: [PATCH] drbd: build: deal with potentially relative paths in prep
step
since linux 13b25489b6f8b (kbuild: change working directory to external module directory with M=, 2024-11-10)
some Kbuild make variables may be relative paths.
Wrap them in $(abspath) as necessary.
---
drbd/Kbuild | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/drbd/Kbuild b/drbd/Kbuild
index ade25d4ee70a..80ec69dcce79 100644
--- a/drbd/Kbuild
+++ b/drbd/Kbuild
@@ -164,7 +164,7 @@ quiet_cmd_splitdiff = SPLIT $<
cmd_splitdiff = \
mkdir -p $(patches-dir) \
&& cd $(patches-dir) \
- && $(PERL) $(src)/drbd-kernel-compat/splitdiff.pl < $<
+ && $(PERL) $(abspath $(src))/drbd-kernel-compat/splitdiff.pl < $(abspath $<)
annotate-orig-pos := \
$(src)/drbd-kernel-compat/annotate-diff-with-original-file-position-pragmas.pl
@@ -188,13 +188,14 @@ quiet_cmd_apply_compat_patch = PATCH $@
if test -s $$patch ; then \
$(PATCH) --output $$out.tmp $$orig $$patch ; \
diff -u $$orig $$out.tmp | \
- DRBDSRC=$(src) \
- OUTDIR=$(obj.build) \
- PATCHES_DIR=$(patches-dir) \
- $(PERL) $(annotate-orig-pos) \
- | $(PATCH) --output $$out $$orig ; \
+ DRBDSRC=$(abspath $(src)) \
+ OUTDIR=$(abspath $(obj.build)) \
+ PATCHES_DIR=$(abspath $(patches-dir)) \
+ $(PERL) $(annotate-orig-pos) > $$out.annotated; \
+ $(PATCH) --output $$out $$orig < $$out.annotated; \
chmod --reference $$orig $$out ; \
: rm -f $$out.tmp; \
+ : rm -f $$out.annotated; \
else { echo "\# 1 \"$$orig\""; cat $$orig; } > $$out; fi
orig-source = $(src)/$(s)
--
2.48.1