03879b9e2b
This commit relocates the "C++ ABI library" components such as global constructor/destructor and initialiser handlers to a dedicated directory, `lib/cpp/abi`, in order to provide a clear separation between the C++ ABI/runtime library and the standard C++ library components. Note that the Zephyr C++ ABI library currently implements the GNU/GCC C++ ABI, which is the de-facto standard ABI used by many compilers including Clang -- it may be necessary to sub-divide the `lib/cpp/abi` into `lib/cpp/abi/gnu` and `lib/cpp/abi/someotherabi` in the future when adding the support for a C++ compiler that expects an ABI vastly different from the GNU C++ ABI. Signed-off-by: Stephanos Ioannidis <stephanos.ioannidis@nordicsemi.no>
32 lines
483 B
C
32 lines
483 B
C
/*
|
|
* Copyright (c) 2021 Synopsys, Inc.
|
|
*
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*
|
|
* Author: Evgeniy Paltsev
|
|
*/
|
|
|
|
#ifdef CONFIG_CPP_STATIC_INIT_GNU
|
|
|
|
void __do_global_ctors_aux(void);
|
|
void __do_init_array_aux(void);
|
|
|
|
void z_cpp_init_static(void)
|
|
{
|
|
__do_global_ctors_aux();
|
|
__do_init_array_aux();
|
|
}
|
|
|
|
#else
|
|
|
|
#ifdef __CCAC__
|
|
void __do_global_ctors_aux(void);
|
|
|
|
void z_cpp_init_static(void)
|
|
{
|
|
__do_global_ctors_aux();
|
|
}
|
|
#endif /* __CCAC__ */
|
|
|
|
#endif /* CONFIG_CPP_STATIC_INIT_GNU */
|