kbuild: mark prepare0 as PHONY to fix external module build
authorIlias Apalodimas <ilias.apalodimas@linaro.org>
Wed, 11 Jun 2025 20:24:38 +0000 (23:24 +0300)
committerTom Rini <trini@konsulko.com>
Wed, 11 Jun 2025 22:21:36 +0000 (16:21 -0600)
Backported from kernel
commit e00d88804814 ("kbuild: mark prepare0 as PHONY to fix external module build")

Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Makefile

index 4e339ef..a31e89d 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1739,6 +1739,7 @@ u-boot.elf: u-boot.bin u-boot-elf.lds
 u-boot-elf.lds: arch/u-boot-elf.lds prepare FORCE
        $(call if_changed_dep,cpp_lds)
 
+PHONY += prepare0
 # MediaTek's ARM-based u-boot needs a header to contains its load address
 # which is parsed by the BootROM.
 # If the SPL build is enabled, the header will be added to the spl binary,
@@ -1950,7 +1951,7 @@ include/config/uboot.release: include/config/auto.conf FORCE
 # version.h and scripts_basic is processed / created.
 
 # Listed in dependency order
-PHONY += prepare archprepare prepare0 prepare1 prepare3
+PHONY += prepare archprepare prepare1 prepare3
 
 # prepare3 is used to check if we are building in a separate output directory,
 # and if so do: