From 4eeb2bc41e43c850d468ed9132c0202f0ddbf638 Mon Sep 17 00:00:00 2001 From: Angus Gratton Date: Wed, 16 Nov 2016 10:35:47 +1100 Subject: [PATCH] build system: Fix embedding files which are themselves generated by the build system Used by secure boot, which generates the secure boot signing key inside build/. --- make/component_wrapper.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/make/component_wrapper.mk b/make/component_wrapper.mk index 55a135158a..6f903f9fce 100644 --- a/make/component_wrapper.mk +++ b/make/component_wrapper.mk @@ -194,7 +194,7 @@ OBJCOPY_EMBED_ARGS := --input binary --output elf32-xtensa-le --binary-architect define GenerateEmbedTarget $(1).$(2).o: $(call resolvepath,$(1),$(COMPONENT_PATH)) | $$(dir $(1)) $(summary) EMBED $$@ - $$(if $$(filter-out $$(notdir $$(abspath $$<)),$$(abspath $$(notdir $$<))), cp $$< $$(notdir $$<) ) # copy input file to build dir, unless already in build dir + $(if $(filter-out $$(notdir $$(abspath $$<)),$$(abspath $$(notdir $$<))), cp $$< $$(notdir $$<) ) # copy input file to build dir, unless already in build dir $$(if $$(subst bin,,$(2)),echo -ne '\0' >> $$(notdir $$<) ) # trailing NUL byte on text output $(OBJCOPY) $(OBJCOPY_EMBED_ARGS) $$(notdir $$<) $$@ rm $$(notdir $$<) -- 2.40.0