diff mbox series

[WIP,07/30] build: modify uses of $(srctree) to assume trailing slash

Message ID ca98f586d81973fcc01826a8f2b1d5754f9c10e0.1709508290.git.ehem+linux@m5p.com (mailing list archive)
State New
Headers show
Series Adding trailing slash to $(*tree) | expand

Commit Message

Elliott Mitchell March 1, 2024, 7:48 p.m. UTC
This isn't much more than `find | sed` to adjust all uses of $(srctree).
This is split into a separate commit to highlight the actual changes to
the build machinery.

Include the instance of $(objtree) in include/uapi/Makefile while at it.

Signed-off-by: Elliott Mitchell <ehem+linux@m5p.com>
---
`grep` was also used to locate things which needed other actions
(notably the non-toplevel Makefile adjustments), but this is roughly:

find . -name Kbuild\* -print0 | xargs -0 sed -i -e's,$(srctree)$,$(srctree:%/=%),' -e's,$(srctree)\([^,/]\),$(srctree:%/=%)\1,g' -es',$(srctree)/,$(srctree),g'

There could be goofs in here or missed bits.  I hope not, but...
---
 include/uapi/Kbuild | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/include/uapi/Kbuild b/include/uapi/Kbuild
index 4b8401173ef5..4d685badb829 100644
--- a/include/uapi/Kbuild
+++ b/include/uapi/Kbuild
@@ -8,7 +8,7 @@  no-export-headers += linux/kvm.h
 endif
 
 ifeq ($(wildcard $(srctree)arch/$(SRCARCH)/include/uapi/asm/kvm_para.h),)
-ifeq ($(wildcard $(objtree)/arch/$(SRCARCH)/include/generated/uapi/asm/kvm_para.h),)
+ifeq ($(wildcard $(objtree)arch/$(SRCARCH)/include/generated/uapi/asm/kvm_para.h),)
 no-export-headers += linux/kvm_para.h
 endif
 endif