kconfig: cpp: Have LIB_CPLUSPLUS depend on ! MINIMAL_LIBC
The C++ STD library is not compatible with the minimal C library. To ensure that users do not accidentally enable LIB_CPLUSPLUS while also enabling a minimal libc library we add a dependency in Kconfig. Also, use depends instead of select between EXCEPTIONS, RTTI, and LIB_CPLUSPLUS as use of select is discouraged in this situation. Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
This commit is contained in:
parent
4f04386e61
commit
540bd67a7d
1 changed files with 6 additions and 4 deletions
|
@ -44,25 +44,25 @@ config STD_CPP2A
|
|||
|
||||
endchoice
|
||||
|
||||
if ! MINIMAL_LIBC
|
||||
|
||||
config LIB_CPLUSPLUS
|
||||
bool "Link with STD C++ library"
|
||||
help
|
||||
Link with STD C++ Library.
|
||||
|
||||
if LIB_CPLUSPLUS
|
||||
|
||||
config EXCEPTIONS
|
||||
bool "Enable C++ exceptions support"
|
||||
select LIB_CPLUSPLUS
|
||||
depends on !MINIMAL_LIBC
|
||||
help
|
||||
This option enables support of C++ exceptions.
|
||||
|
||||
config RTTI
|
||||
bool "Enable C++ RTTI support"
|
||||
select LIB_CPLUSPLUS
|
||||
help
|
||||
This option enables support of C++ RTTI.
|
||||
|
||||
if LIB_CPLUSPLUS
|
||||
|
||||
config ZEPHYR_CPLUSPLUS
|
||||
bool "Use Zephyr C++ Implementation"
|
||||
|
@ -72,4 +72,6 @@ config ZEPHYR_CPLUSPLUS
|
|||
|
||||
endif # LIB_CPLUSPLUS
|
||||
|
||||
endif # ! MINIMAL_LIBC
|
||||
|
||||
endif # CPLUSPLUS
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue