lib: cpp: remove deprecated Kconfigs

These Kconfigs should have been deprecated for more than 2
releases, remove them:

- `CONFIG_CPP_MAIN`
- `CONFIG_CPLUSPLUS`
- `CONFIG_LIB_CPLUSPLUS`
- `CONFIG_EXCEPTIONS`
- `CONFIG_RTTI`

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
This commit is contained in:
Yong Cong Sin 2024-06-17 22:20:38 +08:00 committed by Anas Nashif
commit 67578faefe
6 changed files with 3 additions and 67 deletions

View file

@ -128,17 +128,6 @@ config EXTERNAL_MODULE_LIBCPP
endchoice # LIBCPP_IMPLEMENTATION
config CPP_MAIN
bool "[DEPRECATED] C++ main() function definition"
select DEPRECATED
help
This option used to be necessary to instruct the Zephyr kernel to
call 'int main(void)' instead of the old Zephyr default, 'void
main(void)'.
As the Zephyr type now matches the C++ required type, this option
is no longer necessary.
if !MINIMAL_LIBCPP
config CPP_EXCEPTIONS
@ -164,6 +153,4 @@ config CPP_STATIC_INIT_GNU
endif # CPP
rsource "Kconfig.deprecated"
endmenu

View file

@ -1,50 +0,0 @@
# Copyright (c) 2022 Nordic Semiconductor ASA
# SPDX-License-Identifier: Apache-2.0
menu "Deprecated"
config CPLUSPLUS
bool "[DEPRECATED] C++ support for the application"
select CPP
select DEPRECATED
help
This option enables the use of applications built with C++.
[DEPRECATED] Select CPP instead.
config LIB_CPLUSPLUS
bool "[DEPRECATED] Link with STD C++ library"
select REQUIRES_FULL_LIBC
select REQUIRES_FULL_LIBCPP
select DEPRECATED
help
Link with STD C++ Library.
[DEPRECATED]
Select REQUIRES_FULL_LIBCPP or specify the C++ standard library
implementation to use from LIBCPP_IMPLEMENTATION.
if LIB_CPLUSPLUS
config EXCEPTIONS
bool "[DEPRECATED] C++ exceptions support"
depends on !NEWLIB_LIBC_NANO
select CPP_EXCEPTIONS
select DEPRECATED
help
This option enables support of C++ exceptions.
[DEPRECATED] Select CPP_EXCEPTIONS instead.
config RTTI
bool "[DEPRECATED] C++ RTTI support"
select CPP_RTTI
select DEPRECATED
help
This option enables support of C++ RTTI.
[DEPRECATED] Select CPP_RTTI instead.
endif # LIB_CPLUSPLUS
endmenu

View file

@ -1,4 +1,3 @@
# CONFIG_LIB_CPLUSPLUS Dependencies
CONFIG_REQUIRES_FULL_LIBCPP=y
# CONFIG_THRIFT Dependencies

View file

@ -1,6 +1,6 @@
CONFIG_ZTEST=y
CONFIG_ARCMWDT_LIBC=y
CONFIG_CPLUSPLUS=y
CONFIG_CPP=y
CONFIG_DSP=y
CONFIG_CMSIS_DSP=y
CONFIG_CMSIS_DSP_BASICMATH=y

View file

@ -10,7 +10,7 @@ else()
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
project(base)
if(CONFIG_CPLUSPLUS)
if(CONFIG_CPP)
message(STATUS "adding main.cpp")
target_sources(app PRIVATE src/main.cpp)
else()

View file

@ -12,6 +12,6 @@ tests:
- native_sim
testing.ztest.expect_cpp:
extra_configs:
- CONFIG_CPLUSPLUS=y
- CONFIG_CPP=y
testing.ztest.expect.unit:
type: unit