tinycrypt: move from lib to regular objects
tinycrypt was built using the lib- scripts without any real benefit. We also had a wrong placement of the Kconfig files under misc/ and a Kconfig file for Crypto that was never used before. Change-Id: I82d5902d92e7c06e10a95f418d9ead3cbcabcce4 Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This commit is contained in:
parent
a0cf03b1c7
commit
0b2c44a771
|
@ -30,6 +30,8 @@ source "net/Kconfig"
|
|||
|
||||
source "misc/Kconfig"
|
||||
|
||||
source "lib/Kconfig"
|
||||
|
||||
#
|
||||
# The following are for Kconfig files for default values only.
|
||||
# These should be parsed at the end.
|
||||
|
|
7
Makefile
7
Makefile
|
@ -557,12 +557,7 @@ else
|
|||
include/config/auto.conf: ;
|
||||
endif # $(dot-config)
|
||||
|
||||
ifdef CONFIG_TINYCRYPT
|
||||
# Objects we will link into the kernel / subdirs we need to visit
|
||||
KCRYPTO_DIR := lib/crypto/tinycrypt
|
||||
libs-y += $(KCRYPTO_DIR)/
|
||||
ZEPHYRINCLUDE += -I$(srctree)/lib/crypto/tinycrypt/include
|
||||
endif
|
||||
-include $(srctree)/lib/Makefile
|
||||
|
||||
ARCH = $(subst $(DQUOTE),,$(CONFIG_ARCH))
|
||||
export ARCH
|
||||
|
|
2
lib/Kbuild
Normal file
2
lib/Kbuild
Normal file
|
@ -0,0 +1,2 @@
|
|||
obj-y += libc/
|
||||
obj-y += crypto/
|
|
@ -1,7 +1,5 @@
|
|||
# Kconfig - cryptography configuration options
|
||||
|
||||
#
|
||||
# Copyright (c) 2015 Intel Corporation
|
||||
# Copyright (c) 2016 Intel Corporation
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
|
@ -16,8 +14,8 @@
|
|||
# limitations under the License.
|
||||
#
|
||||
|
||||
|
||||
menu "Cryptography"
|
||||
|
||||
source "tinycrypt/Kconfig"
|
||||
|
||||
source "lib/crypto/tinycrypt/Kconfig"
|
||||
endmenu
|
||||
|
|
@ -1 +1,4 @@
|
|||
obj-y := libc/
|
||||
|
||||
ifeq ($(CONFIG_TINYCRYPT),y)
|
||||
ZEPHYRINCLUDE += -I$(srctree)/lib/crypto/tinycrypt/include
|
||||
endif
|
||||
|
|
|
@ -1 +1 @@
|
|||
libs-$(CONFIG_TINYCRYPT) += tinycrypt/
|
||||
obj-$(CONFIG_TINYCRYPT) += tinycrypt/
|
||||
|
|
|
@ -1,14 +1,15 @@
|
|||
ccflags-y +=-I$(srctree)/lib/crypto/tinycrypt/include
|
||||
lib-$(CONFIG_TINYCRYPT) := source/utils.o
|
||||
lib-$(CONFIG_TINYCRYPT_ECC_DH) += source/ecc_dh.o source/ecc.o
|
||||
lib-$(CONFIG_TINYCRYPT_ECC_DSA) += source/ecc_dsa.o source/ecc.o
|
||||
lib-$(CONFIG_TINYCRYPT_AES) += source/aes_decrypt.o
|
||||
lib-$(CONFIG_TINYCRYPT_AES) += source/aes_encrypt.o
|
||||
lib-$(CONFIG_TINYCRYPT_AES_CBC) += source/cbc_mode.o
|
||||
lib-$(CONFIG_TINYCRYPT_AES_CTR) += source/ctr_mode.o
|
||||
lib-$(CONFIG_TINYCRYPT_AES_CCM) += source/ccm_mode.o
|
||||
lib-$(CONFIG_TINYCRYPT_AES_CMAC) += source/cmac_mode.o
|
||||
lib-$(CONFIG_TINYCRYPT_SHA256) += source/sha256.o
|
||||
lib-$(CONFIG_TINYCRYPT_SHA256) += source/utils.o
|
||||
lib-$(CONFIG_TINYCRYPT_SHA256_HMAC) += source/hmac.o
|
||||
lib-$(CONFIG_TINYCRYPT_SHA256_HMAC_PRNG) += source/hmac_prng.o
|
||||
subdir-ccflags-y +=-I$(srctree)/lib/crypto/tinycrypt/include
|
||||
|
||||
obj-$(CONFIG_TINYCRYPT) := source/utils.o
|
||||
obj-$(CONFIG_TINYCRYPT_ECC_DH) += source/ecc_dh.o source/ecc.o
|
||||
obj-$(CONFIG_TINYCRYPT_ECC_DSA) += source/ecc_dsa.o source/ecc.o
|
||||
obj-$(CONFIG_TINYCRYPT_AES) += source/aes_decrypt.o
|
||||
obj-$(CONFIG_TINYCRYPT_AES) += source/aes_encrypt.o
|
||||
obj-$(CONFIG_TINYCRYPT_AES_CBC) += source/cbc_mode.o
|
||||
obj-$(CONFIG_TINYCRYPT_AES_CTR) += source/ctr_mode.o
|
||||
obj-$(CONFIG_TINYCRYPT_AES_CCM) += source/ccm_mode.o
|
||||
obj-$(CONFIG_TINYCRYPT_AES_CMAC) += source/cmac_mode.o
|
||||
obj-$(CONFIG_TINYCRYPT_SHA256) += source/sha256.o
|
||||
obj-$(CONFIG_TINYCRYPT_SHA256) += source/utils.o
|
||||
obj-$(CONFIG_TINYCRYPT_SHA256_HMAC) += source/hmac.o
|
||||
obj-$(CONFIG_TINYCRYPT_SHA256_HMAC_PRNG) += source/hmac_prng.o
|
||||
|
|
|
@ -16,11 +16,6 @@
|
|||
# limitations under the License.
|
||||
#
|
||||
|
||||
|
||||
menu "Cryptography"
|
||||
source "lib/crypto/tinycrypt/Kconfig"
|
||||
endmenu
|
||||
|
||||
menu "Compile and Link Features"
|
||||
|
||||
config KERNEL_BIN_NAME
|
||||
|
|
Loading…
Reference in a new issue