mirror of
https://github.com/apache/nuttx.git
synced 2026-05-29 20:56:47 +08:00
risc-v/esp32c3: Fix inclusion of C++ constructors/destructors table
RISC-V GCC is configured with --enable-initfini-array so it emits an .init_array section instead of .ctors Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
This commit is contained in:
committed by
Xiang Xiao
parent
c7311829e0
commit
a0617177e8
@@ -161,13 +161,14 @@ SECTIONS
|
|||||||
KEEP(*(.eh_frame))
|
KEEP(*(.eh_frame))
|
||||||
. = (. + 7) & ~ 3;
|
. = (. + 7) & ~ 3;
|
||||||
|
|
||||||
/* C++ constructor and destructor tables: */
|
/* C++ constructor and destructor tables:
|
||||||
|
* RISC-V GCC is configured with --enable-initfini-array so it emits an
|
||||||
|
* .init_array section instead.
|
||||||
|
*/
|
||||||
|
|
||||||
_sinit = ABSOLUTE(.);
|
_sinit = ABSOLUTE(.);
|
||||||
KEEP (*crtbegin.o(.ctors))
|
KEEP (*(EXCLUDE_FILE (*crtend.* *crtbegin.*) .init_array.*))
|
||||||
KEEP (*(EXCLUDE_FILE (*crtend.o) .ctors))
|
KEEP (*(EXCLUDE_FILE (*crtend.* *crtbegin.*) .init_array))
|
||||||
KEEP (*(SORT(.ctors.*)))
|
|
||||||
KEEP (*(.ctors))
|
|
||||||
_einit = ABSOLUTE(.);
|
_einit = ABSOLUTE(.);
|
||||||
KEEP (*crtbegin.o(.dtors))
|
KEEP (*crtbegin.o(.dtors))
|
||||||
KEEP (*(EXCLUDE_FILE (*crtend.o) .dtors))
|
KEEP (*(EXCLUDE_FILE (*crtend.o) .dtors))
|
||||||
|
|||||||
Reference in New Issue
Block a user