[PATCH v2] kbuild: strip sub_make_done from test-script environment
Tom Rini
trini at konsulko.com
Mon Mar 16 19:07:38 CET 2026
On Wed, 04 Mar 2026 11:48:53 -0700, Simon Glass wrote:
> The exported sub_make_done variable leaks into the environment of all
> child processes. When make targets like tcheck spawn independent
> make-invocations with O=, those child-makes inherit sub_make_done=1,
> skip the KBUILD_OUTPUT setup and try to build in the source tree.
>
> A global 'unexport sub_make_done' cannot be used because the build
> system itself re-invokes the top-level Makefile for syncconfig (via
> '$(MAKE) -f $(srctree)/Makefile syncconfig'). Without sub_make_done,
> that child make re-enters the KBUILD_OUTPUT block and recomputes
> abs_objtree. With a relative O= path this resolves to a nested
> directory (e.g. build/build/) where .config does not exist.
>
> [...]
Applied to u-boot/next, thanks!
[1/1] kbuild: strip sub_make_done from test-script environment
commit: a27980786cfb3c430aa1c05da8e79180c584d221
--
Tom
More information about the U-Boot
mailing list