Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions netutils/dropbear/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -192,8 +192,13 @@ if(CONFIG_NETUTILS_DROPBEAR)
endif()

target_compile_definitions(
${PROGNAME} PRIVATE LOCALOPTIONS_H_EXISTS=1 DROPBEAR_NUTTX=1
DROPBEAR_NUTTX_PASSWD=1)
${PROGNAME}
PRIVATE LOCALOPTIONS_H_EXISTS=1
DROPBEAR_NUTTX=1
DROPBEAR_NUTTX_PASSWD=1
base64_encode=dropbear_ltc_base64_encode
base64_decode=dropbear_ltc_base64_decode
ecc_make_key=dropbear_ltc_ecc_make_key)

if(CONFIG_NETUTILS_DROPBEAR_SCP)
target_compile_definitions(
Expand Down
7 changes: 7 additions & 0 deletions netutils/dropbear/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,13 @@ endif
# Match the ESP-IDF port behavior: LTC_SOURCE is only for libtomcrypt sources.
$(foreach src,$(TOMCRYPT_SRCS),$(eval $(src)_CFLAGS += ${DEFINE_PREFIX}LTC_SOURCE=1))

# Avoid duplicate symbols when NuttX/apps also provide these APIs.
# Apply to all dropbear sources so libtomcrypt definitions and dropbear
# callers (e.g. signkey.c) use the same renamed symbols.
CFLAGS += ${DEFINE_PREFIX}base64_encode=dropbear_ltc_base64_encode
CFLAGS += ${DEFINE_PREFIX}base64_decode=dropbear_ltc_base64_decode
CFLAGS += ${DEFINE_PREFIX}ecc_make_key=dropbear_ltc_ecc_make_key

MAINSRC = dropbear_main.c

ifneq ($(CONFIG_NETUTILS_DROPBEAR_SCP),)
Expand Down
Loading