[PATCH v2 13/30] xpl: Define CONFIG_SPL_BUILD only for the SPL build

Jonas Karlman jonas at kwiboo.se
Sun Sep 29 00:18:59 CEST 2024


Hi Simon,

On 2024-09-28 22:00, Simon Glass wrote:
> Make this define mean SPL only, not TPL, VPL, etc.
> 
> Signed-off-by: Simon Glass <sjg at chromium.org>
> ---
> 
> (no changes since v1)
> 
>  scripts/Makefile.autoconf | 4 ++--
>  scripts/Makefile.xpl      | 9 ++++++---
>  2 files changed, 8 insertions(+), 5 deletions(-)
> 

[snip]

> --- a/scripts/Makefile.xpl
> +++ b/scripts/Makefile.xpl
> @@ -21,9 +21,10 @@ include $(srctree)/scripts/Kbuild.include
>  
>  -include include/config/auto.conf
>  
> -# This file contains 0, 2 or 3 lines
> +# This file contains 0, or 2 lines
>  # It is empty for U-Boot proper (where $(obj) is empty)
> -# For any xPL build it contains CONFIG_SPL_BUILD=y and CONFIG_XPL_BUILD=y
> +# For any xPL build it contains CONFIG_XPL_BUILD=y
> +#    - for SPL builds it also contains CONFIG_SPL_BUILD=y
>  #    - for TPL builds it also contains CONFIG_TPL_BUILD=y
>  #    - for VPL builds it also contains CONFIG_VPL_BUILD=y
>  -include $(obj)/include/autoconf.mk
> @@ -31,7 +32,9 @@ include $(srctree)/scripts/Kbuild.include
>  UBOOTINCLUDE := -I$(obj)/include $(UBOOTINCLUDE)
>  
>  KBUILD_CPPFLAGS += -DCONFIG_XPL_BUILD
> -KBUILD_CPPFLAGS += -DCONFIG_XPL_BUILD

This change look strange and this line should have defined
CONFIG_SPL_BUILD prior to this patch.

Regards,
Jonas

> +ifeq ($(CONFIG_SPL_BUILD),y)
> +KBUILD_CPPFLAGS += -DCONFIG_SPL_BUILD
> +endif
>  ifeq ($(CONFIG_TPL_BUILD),y)
>  KBUILD_CPPFLAGS += -DCONFIG_TPL_BUILD
>  else



More information about the U-Boot mailing list