Re: [PATCH v2 4/4] kbuild: use $(src) instead of $(srctree)/$(src) for source directory
From: Edgecombe, Rick P
Date: Thu Jun 27 2024 - 13:14:12 EST
On Fri, 2024-05-10 at 04:36 +0900, Masahiro Yamada wrote:
>
> Or, fix the code.
>
>
> Now fixed. Thanks for the report.
>
Hi,
This commit broke my build in a similar way:
make ARCH=x86_64 O=../linux-tdx-kvm-out/ -j36 M=arch/x86/kvm/
make[1]: Entering directory '/home/rpedgeco/repos/linux-tdx-kvm-out'
/home/rpedgeco/repos/linux/scripts/Makefile.build:41: arch/x86/kvm/Makefile: No
such file or directory
make[3]: *** No rule to make target 'arch/x86/kvm/Makefile'. Stop.
make[2]: *** [/home/rpedgeco/repos/linux/Makefile:1934: arch/x86/kvm] Error 2
make[1]: *** [/home/rpedgeco/repos/linux/Makefile:240: __sub-make] Error 2
make[1]: Leaving directory '/home/rpedgeco/repos/linux-tdx-kvm-out'
make: *** [Makefile:240: __sub-make] Error 2
This patch didn’t fix it:
https://lore.kernel.org/lkml/20240624-kbuild-fix-xconfig-v1-1-7c06eae6d3aa@xxxxxx/
But reverting b1992c3772e6 ("kbuild: use $(src) instead of $(srctree)/$(src) for
source directory") does.
I'm guess it has something to do with the "M=" option because:
make ARCH=x86_64 O=../linux-tdx-kvm-out/ -j36 arch/x86/kvm/kvm.ko
arch/x86/kvm/kvm-intel.ko
...works.