cmake: Compute TOOLCHAIN_HAS_NEWLIB at cmake time
Switch from using a generator expression to computing the value with a conditional so that it is available during the execution of kconfig instead of only being available while generating the build script. Signed-off-by: Keith Packard <keithp@keithp.com>
This commit is contained in:
parent
4134858868
commit
638842c598
1 changed files with 7 additions and 1 deletions
|
@ -113,6 +113,12 @@ string(REPLACE ";" "\\\;" SHIELD_AS_LIST_ESCAPED "${SHIELD_AS_LIST}")
|
|||
# cmake commands are escaped differently
|
||||
string(REPLACE ";" "\\;" SHIELD_AS_LIST_ESCAPED_COMMAND "${SHIELD_AS_LIST}")
|
||||
|
||||
if(TOOLCHAIN_HAS_NEWLIB)
|
||||
set(_local_TOOLCHAIN_HAS_NEWLIB y)
|
||||
else()
|
||||
set(_local_TOOLCHAIN_HAS_NEWLIB n)
|
||||
endif()
|
||||
|
||||
set(COMMON_KCONFIG_ENV_SETTINGS
|
||||
PYTHON_EXECUTABLE=${PYTHON_EXECUTABLE}
|
||||
srctree=${ZEPHYR_BASE}
|
||||
|
@ -128,7 +134,7 @@ set(COMMON_KCONFIG_ENV_SETTINGS
|
|||
KCONFIG_BINARY_DIR=${KCONFIG_BINARY_DIR}
|
||||
ZEPHYR_TOOLCHAIN_VARIANT=${ZEPHYR_TOOLCHAIN_VARIANT}
|
||||
TOOLCHAIN_KCONFIG_DIR=${TOOLCHAIN_KCONFIG_DIR}
|
||||
TOOLCHAIN_HAS_NEWLIB=$<IF:$<BOOL:${TOOLCHAIN_HAS_NEWLIB}>,y,n>
|
||||
TOOLCHAIN_HAS_NEWLIB=${_local_TOOLCHAIN_HAS_NEWLIB}
|
||||
EDT_PICKLE=${EDT_PICKLE}
|
||||
# Export all Zephyr modules to Kconfig
|
||||
${ZEPHYR_KCONFIG_MODULES_DIR}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue