Commit 09ef1c4b authored by David Brown's avatar David Brown Committed by David Brown
Browse files

zephyr: Reconfigure to use local tinycrypt

Disable the Zephyr-provided Tinycrypt, and use our local copy.  This
avoids problems with changing version across different Zephyr releases.

Signed-off-by: default avatarDavid Brown <david.brown@linaro.org>
parent fecda2d6
Loading
Loading
Loading
Loading
+2
Changes for Makefile: 2 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -15,6 +15,8 @@ CFLAGS += -DMCUBOOT_SIGN_RSA -DMCUBOOT_USE_MBED_TLS
# ECDSA P-256
#CONF_FILE = boot/zephyr/prj-p256.conf
#CFLAGS += -DMCUBOOT_SIGN_EC256 -DMCUBOOT_USE_TINYCRYPT
#NEED_TINYCRYPT = y
#export NEED_TINYCRYPT

# Enable this option to have the bootloader verify the signature of
# the primary image upon every boot.  Without it, signature
+3
Changes for boot/zephyr/Makefile: 3 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -8,3 +8,6 @@ obj-y += flash_map.o hal_flash.o os.o
obj-y += keys.o

obj-y += ../bootutil/src/

obj-$(NEED_TINYCRYPT) += ../../ext/tinycrypt/lib/source/
include $(PROJECT)/ext/tinycrypt/lib/source/Makefile.inc
+3 −3
Changes for boot/zephyr/prj-p256.conf: 3 added lines, 3 removed lines.
Original line number Diff line number Diff line
@@ -7,9 +7,9 @@ CONFIG_MAIN_STACK_SIZE=10240
CONFIG_MBEDTLS=y
CONFIG_MBEDTLS_BUILTIN=y
CONFIG_MBEDTLS_CFG_FILE="config-asn1.h"
CONFIG_TINYCRYPT=y
CONFIG_TINYCRYPT_ECC_DSA=y
CONFIG_TINYCRYPT_SHA256=y
# CONFIG_TINYCRYPT is not set
# CONFIG_TINYCRYPT_ECC_DSA is not set
# CONFIG_TINYCRYPT_SHA256 is not set

### mbedTLS wants a heap
CONFIG_HEAP_MEM_POOL_SIZE=16384
+4
Changes for ext/tinycrypt/lib/source/Makefile: 4 added lines, 0 removed lines.
Original line number Diff line number Diff line
# Zephyr makefile.
# subdir-ccflags-y += -I$(PROJECT)/ext/tinycrypt/lib/include

obj-y += ecc.o ecc_dsa.o sha256.o utils.o
+3
Changes for ext/tinycrypt/lib/source/Makefile.inc: 3 added lines, 0 removed lines.
Original line number Diff line number Diff line
# vim: ft=make

subdir-ccflags-$(NEED_TINYCRYPT) += -I$(PROJECT)/ext/tinycrypt/lib/include