summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorStefano Manni <stefano.manni@gmail.com>2022-07-20 12:15:22 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2022-08-09 09:04:17 +0200
commitf64e6124b4666f347524841d2bb2036d5897c299 (patch)
treea50f17afe83c881282649a88229768dfe4eb3011 /scripts
parent6fff3e73bb62ef18e90ff60ea5d982727252b5f7 (diff)
downloadbarebox-f64e6124b4666f347524841d2bb2036d5897c299.tar.gz
kbuild: make FIT public key overwritable
The path to the public key used to verify FIT images can be specified with Kconfig variable. For a better build system integration we also want to be able to specify the path in environment variables. Signed-off-by: Stefano Manni <stefano.manni@gmail.com> Link: https://lore.barebox.org/02bcbd486b7f41e5dc86bf9d228dcbf6e1fe9957.camel@gmail.com Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/Makefile.lib8
1 files changed, 7 insertions, 1 deletions
diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
index a830364a8b..15d5319c48 100644
--- a/scripts/Makefile.lib
+++ b/scripts/Makefile.lib
@@ -519,6 +519,11 @@ overwrite-hab-env = $(shell set -e; \
test -n "$$$(1)"; \
echo -D$(1)=\\\"$(shell echo $$$(1))\\\")
+overwrite-fit-env = $(shell set -e; \
+ test -n "$(CONFIG_BOOTM_FITIMAGE_PUBKEY_ENV)"; \
+ test -n "$$$(1)"; \
+ echo -D$(1)=\\\"$(shell echo $$$(1))\\\")
+
imxcfg_cpp_flags = -Wp,-MD,$(depfile) -nostdinc -x assembler-with-cpp \
-I $(srctree)/include -I $(srctree)/arch/arm/mach-imx/include \
-include include/generated/autoconf.h \
@@ -527,7 +532,8 @@ imxcfg_cpp_flags = -Wp,-MD,$(depfile) -nostdinc -x assembler-with-cpp \
$(call overwrite-hab-env,CONFIG_HABV3_IMG_CRT_DER) \
$(call overwrite-hab-env,CONFIG_HABV4_TABLE_BIN) \
$(call overwrite-hab-env,CONFIG_HABV4_CSF_CRT_PEM) \
- $(call overwrite-hab-env,CONFIG_HABV4_IMG_CRT_PEM)
+ $(call overwrite-hab-env,CONFIG_HABV4_IMG_CRT_PEM) \
+ $(call overwrite-fit-env,CONFIG_BOOTM_FITIMAGE_PUBKEY) \
dcd-tmp = $(subst $(comma),_,$(dot-target).dcd.tmp)