kconfig: libmetal: Have LIBMETAL_SRC_PATH depend on LIBMETAL

Kconfig options are often either of the type 'feature' or
'configuration'. Meaning, either an option controls whether a feature
is enabled, or it adjusts/configures an already enabled feature.

Configuration of features should depend on the feature they are
configuring or else noise is created both in the Kconfig output and in
the Kconfig menu.

In this commit we add a dependency from a configuration option to it's
feature option.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
This commit is contained in:
Sebastian Bøe 2018-12-27 15:33:00 +01:00 committed by Anas Nashif
parent 0715015c75
commit 45857563ff
1 changed files with 5 additions and 1 deletions

View File

@ -4,13 +4,17 @@
# SPDX-License-Identifier: Apache-2.0
#
config LIBMETAL
menuconfig LIBMETAL
bool "libmetal Support"
help
This option enables the libmetal HAL abstraction layer
if LIBMETAL
config LIBMETAL_SRC_PATH
string "libmetal library source path"
default "libmetal"
help
This option specifies the path to the source for the libmetal library
endif # LIBMETAL