zephyr/arch
Eugeniy Paltsev a28ec6201f isr_tables: don't whole-archive library
As of today we have a bit weird situation with generated
sw_isr_table / irq_vector_table tables.

On the final linkage stage we pass two files which content
section with sw_isr_table / irq_vector_table. They are
 * libarch__common.a (with an outdated tables from the first
   linkage stage)
 * isr_tables.c.obj (with an actual tables)

The sections where tables are located are marked with
".gnu.linkonce" prefix. That means:
<<<As a GNU extension, if the name begins with .gnu.linkonce,
we only link a single copy of the section.>>>

However the "libarch__common.a" is passed to linker with
"--whole-archive" option which means <<<include every object
file in the archive in the link, rather than searching the archive
for the required object files>>>

That combination confuses MWDT linker and breaks linkage with
MWDT toolchain.

As a simple fix we can move the sw_isr_table / irq_vector_table
sections to their own library and link this library with
"--no-whole-archive" option.

Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
2020-09-05 10:22:56 -05:00
..
arc ARC: rename arch_switch implementation to z_arc_switch 2020-09-05 10:22:56 -05:00
arm arch: arm64: Use _arch_switch() API 2020-09-05 12:06:38 +02:00
common isr_tables: don't whole-archive library 2020-09-05 10:22:56 -05:00
nios2 arch: Apply dynamic IRQ API change 2020-09-02 13:48:13 +02:00
posix toolchain: improved toolchain abstraction for compilers and linker 2020-09-04 20:36:59 +02:00
riscv arch: Apply dynamic IRQ API change 2020-09-02 13:48:13 +02:00
x86 toolchain: improved toolchain abstraction for compilers and linker 2020-09-04 20:36:59 +02:00
xtensa isr: Normalize usage of device instance through ISR 2020-09-02 13:48:13 +02:00
CMakeLists.txt cmake: fix include directories to work with out-of-tree arch 2020-08-05 08:06:07 -04:00
Kconfig mmu: support only identity RAM mapping 2020-09-03 14:24:38 -04:00