Introduce HAS_NEWLIB_LIBC_NANO Kconfig option that the toolchain
specific Kconfig (gnuarmemb & zephyr 0.11) can select to convey that the
feature is supported.
This removes the need to if protect the NEWLIB_LIBC_NANO Kconfig with:
if "$(ZEPHYR_TOOLCHAIN_VARIANT)" = "gnuarmemb"
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Allow a given toolchain to specify Kconfig options that might be
relevant to a feature available in that toolchain.
For example, the ARM embedded GNU toolchain supports two variants of
newlib and you select the smaller one via a spec file. We can use a
Kconfig option like HAS_NEWLIB_LIBC_NANO to convey that this feature is
supported by that toolchain.
We look for the toolchain Kconfig in ${TOOLCHAIN_KCONFIG_DIR}/Kconfig,
and default TOOLCHAIN_KCONFIG_DIR to:
${TOOLCHAIN_ROOT}/cmake/toolchain/${ZEPHYR_TOOLCHAIN_VARIANT})
toolchain specific cmake files can override the default if needed.
Additionally tweaked the zephyr/generic.cmake to use
${CMAKE_CURRENT_LIST_DIR} to reduce some duplication.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>