Open-CMSIS-Pack / devtools

Open-CMSIS-Pack development tools - C++
Apache License 2.0
73 stars 55 forks source link

Why are there some linker errors with default scripts #902

Open ReinhardKeil opened 1 year ago

ReinhardKeil commented 1 year ago

With the NXP RT1064 device, there is a linker error when using default linker scripts

"C:/w/csolution-examples/RT1064/tmp/RT1064/Device/Debug/ac6_linker_script.sct.pp", line 14 (column 9): Error: L6236E: No section matches selector - no section to be FIRST/LAST.

What is causing this error?


With the LPC1786 project this warning is reported (which is understandable).

"C:/w/csolution-examples/LPC1768/tmp/LPC1786/Device/Debug/ac6_linker_script.sct.pp", line 20 (column 7): Warning: L6314W: No section matches pattern *(.bss.noinit).

Should we disable this warning by default?

Both projects are in Linker.zip under #901

brondani commented 1 year ago

It seems in the RT1064 example the startup file names the vector table section as .isr_vector, while in the default linker script the first section is expected to be named RESET.

JonatanAntoni commented 1 year ago

The RT1064 example, or to be more specific the RT1064 startup component, uses custom (non-CMSIS) assembly startup code. This is not compatible with the default linker scripts shipped with CMSIS-Toolbox. The default linker scripts are written for the default CMSIS C-Startup code using the provisions from CMSIS-Core(M).

ReinhardKeil commented 1 month ago

Related to #1699