On 12/16/25 3:16 AM, Ilias Apalodimas wrote: > From: Sughosh Ganu <[email protected]> > > Our last sync with the kernel was 5.1. > > We are so out of sync now, that tracking the patches and backporting > them one by one makes little sense and it's going to take ages. > > This is an attempt to sync up Makefiles to 6.1. > Unfortunately due to sheer amount of patches this is not easy to review, > but that's what we decided during a community call for the bump to 5.1, > so we are following the same guidelines here. > > Signed-off-by: Sughosh Ganu <[email protected]> > Signed-off-by: Ilias Apalodimas <[email protected]>a #rebased on > -next >
... > @@ -129,14 +131,14 @@ include/config.h: scripts/Makefile.autoconf > create_symlink FORCE > PHONY += create_symlink > create_symlink: > ifdef CONFIG_CREATE_ARCH_SYMLINK > -ifneq ($(KBUILD_SRC),) > +ifdef building_out_of_srctree > $(Q)mkdir -p include/asm > - $(Q)if [ -d $(KBUILD_SRC)/arch/$(ARCH)/mach-$(SOC)/include/mach ]; then > \ > + $(Q)if [ -d $(srctree)/arch/$(ARCH)/mach-$(SOC)/include/mach ]; then > \ > dest=arch/$(ARCH)/mach-$(SOC)/include/mach; > \ > else > \ > dest=arch/$(ARCH)/include/asm/arch-$(if $(SOC),$(SOC),$(CPU)); > \ > fi; > \ > - ln -fsn $(KBUILD_SRC)/$$dest include/asm/arch > + ln -fsn $(srctree)/$$dest include/asm/arch > else > $(Q)if [ -d arch/$(ARCH)/mach-$(SOC)/include/mach ]; then \ > dest=../../mach-$(SOC)/include/mach; \ This breaks out-of-tree builds because the symlink created is broken. For example, I have O=build-mt8365_evk so the build directory is a subdirectory of the source directory. This causes $(srctree) to be ".." and therefore the link is: build-mt8365_evk/include/asm/arch -> ../arch/arm/include/asm/arch-mediatek Obviously, there should be a few more ../ in there or it should use an absolute path. I'm guessing previously $(KBUILD_SRC) was an absolute path? I will see if I can come up with a fix unless someone has any immediate suggestions.

