‑‑cpp_init_routine
In this section:
Syntax
Parameters
| A user-defined C++ dynamic initialization routine. |
Description
When using the IAR C/C++ compiler and the standard library, C++ dynamic initialization is handled automatically. In other cases you might need to use this option.
If any sections with the section type INIT_ARRAY or PREINIT_ARRAY are included in your application, the C++ dynamic initialization routine is considered to be needed. By default, this routine is named __iar_cstart_call_ctors and is called by the startup code in the standard library. Use this option if you require another routine to handle the initialization, for instance if you are not using the standard library.
Caution
To set this option, use Project>Options>Linker>Extra Options.