feat(wolfssl): add wolfssl debug option

This commit is contained in:
Zhang Jun Hao
2019-01-14 14:56:25 +08:00
parent 8209aebd9f
commit 38a29a64db
2 changed files with 16 additions and 0 deletions

View File

@ -16,6 +16,17 @@ config SSL_USING_WOLFSSL
bool "wolfSSL"
endchoice
menu "wolfSSL"
depends on SSL_USING_WOLFSSL
config WOLFSSL_DEBUG
bool "Enable wolfSSL debugging"
default n
help
Enable wolfSSL debugging functions at compile time.
endmenu # wolfSSL
menu "mbedTLS"
depends on SSL_USING_MBEDTLS

View File

@ -5,8 +5,13 @@
ifdef CONFIG_SSL_USING_WOLFSSL
COMPONENT_ADD_INCLUDEDIRS := wolfssl/include wolfssl/wolfssl wolfssl/wolfssl/wolfssl
ifdef CONFIG_WOLFSSL_DEBUG
WOLFSSLLIB = wolfssl_debug
COMPONENT_ADD_LDFLAGS := -L $(COMPONENT_PATH)/wolfssl/lib -lwolfssl_debug
else
WOLFSSLLIB = wolfssl
COMPONENT_ADD_LDFLAGS := -L $(COMPONENT_PATH)/wolfssl/lib -lwolfssl
endif
# re-link program if wolfssl library change
COMPONENT_ADD_LINKER_DEPS := $(patsubst %,$(COMPONENT_PATH)/wolfssl/lib/lib%.a,$(WOLFSSLLIB))