On Mon, Jun 20, 2022 at 04:08:51PM +0200, Ahmad Fatoum wrote:
> To assemble FIT images outside TF-A, we will need to collect more
> than can be expressed by a single wildcard, so extend TF_A_ARTIFACTS
> to support multiple space separated patterns.
> 
> Signed-off-by: Ahmad Fatoum <[email protected]>
> ---
> v1 -> v2:
>   - predefine TF_A_EXTRA_ARGS and TF_A_BINDIR to simplify (mol)
>   - use addprefix instead of nested foreach
> ---
>  rules/tf-a.make | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/rules/tf-a.make b/rules/tf-a.make
> index 7695a4c546e3..3f0815a8a6ee 100644
> --- a/rules/tf-a.make
> +++ b/rules/tf-a.make
> @@ -40,6 +40,8 @@ TF_A_ARTIFACTS              := $(call remove_quotes, 
> $(PTXCONF_TF_A_ARTIFACTS))
>  TF_A_WRAPPER_BLACKLIST       := \
>       $(PTXDIST_LOWLEVEL_WRAPPER_BLACKLIST)
>  
> +TF_A_EXTRA_ARGS              := $(call 
> remove_quotes,$(PTXCONF_TF_A_EXTRA_ARGS))
> +TF_A_BINDIR           = $(TF_A_BUILDDIR)/$(1)/$(if $(filter 
> DEBUG=1,$(TF_A_EXTRA_ARGS)),debug,release)
>  TF_A_PATH    := PATH=$(CROSS_PATH)
>  TF_A_MAKE_OPT        := \
>       -C $(TF_A_DIR) \
> @@ -48,7 +50,7 @@ TF_A_MAKE_OPT       := \
>       ARCH=$(PTXCONF_TF_A_ARCH_STRING) \
>       ARM_ARCH_MAJOR=$(PTXCONF_TF_A_ARM_ARCH_MAJOR) \
>       BUILD_STRING=$(PTXCONF_TF_A_VERSION) \
> -     $(call remove_quotes,$(PTXCONF_TF_A_EXTRA_ARGS)) \
> +     $(TF_A_EXTRA_ARGS) \
>       all
>  
>  ifdef PTXCONF_TF_A_BL32_TSP
> @@ -89,7 +91,7 @@ $(STATEDIR)/tf-a.compile:
>  # 
> ----------------------------------------------------------------------------
>  
>  tf-a/inst_plat = $(foreach artifact, \
> -     $(wildcard $(TF_A_BUILDDIR)/$(1)/$(if $(filter DEBUG=1,$(call 
> remove_quotes,$(PTXCONF_TF_A_EXTRA_ARGS))),debug,release)/$(TF_A_ARTIFACTS)), 
> \
> +     $(wildcard $(addprefix $(TF_A_BINDIR)/, $($(TF_A_ARTIFACTS)))), \
                    ----------------------------^^

one $() too many here. I'll fix it while applying.

Michael

>       install -v -D -m 644 $(artifact) \
>               $(2)/$(1)-$(notdir $(artifact))$(ptx/nl))
>  
> -- 
> 2.30.2
> 
> 
> 

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

Reply via email to