build: Sign board configuration data on HS ti2019.05 ti2019.05-rc2 ti2019.05-rc3 ti2019.05-rc4
authorAndrew F. Davis <afd@ti.com>
Mon, 30 Sep 2019 15:47:02 +0000 (11:47 -0400)
committerAndreas Dannenberg <dannenberg@ti.com>
Mon, 4 Nov 2019 18:42:53 +0000 (12:42 -0600)
Starting with SYSFW v2019.09 it will be required for board config
binaries to be signed to ensure trust through authentication.
Add this signing step here.

Signed-off-by: Andrew F. Davis <afd@ti.com>
Makefile

index 1d9e5f1cef996a216b1a721c578f3f1e19186ede..88a0f4872335eb4ce6ff5e51c281ee91ee2c32d2 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -169,9 +169,16 @@ soc_objs: $(SOC_OBJS)
 $(soc_objroot)/%.o: %.c
        $(CROSS_COMPILE)gcc $(CFLAGS) -c -o $@ $<
 
+# On HS board configuration binaries must be signed
+ifdef HS
+%.bin.unsigned: %.o
+       $(CROSS_COMPILE)objcopy -S -O binary $< $@
+%.bin: %.bin.unsigned
+       $(TI_SECURE_DEV_PKG)/scripts/secure-binary-image.sh $< $@
+else
 %.bin: %.o
        $(CROSS_COMPILE)objcopy -S -O binary $< $@
-
+endif
 
 .PHONY: sysfw_version
 sysfw_version: $(SYSFW_PATH)