Skip to content
Commit e4c11fd8 authored by Marcin Niestroj's avatar Marcin Niestroj Committed by Carles Cufí
Browse files

modules: mbedtls: support extracting __FILE__ basename at buildtime



So far there was a runtime basename extraction of filenames passed to
mbedTLS debug hook. This has both runtime penalty as well as code size
penalty.

Introduce a buildtime support of extracting basename of source filenames
logged using logging subsystem, so that there is no need to do it at
runtime.

Provide Kconfig options for both buildtime and runtime basename extraction,
as in some cases the buildtime basename extraction might not work,
depending on toolchain used for building Zephyr. Default to buildtime when
using Zephyr SDK, as that is proven to work. Use runtime basename
extraction in other cases (other toolchains used).

This saves approximately 204 bytes of code footprint for sample
application with native TLS sockets built for nRF52840.

Signed-off-by: default avatarMarcin Niestroj <m.niestroj@emb.dev>
parent 6653fd94
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment