Error while creating linker script

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Error while creating linker script

Jump to solution
2,617 Views
DridriLaBastos
Contributor I

I was working on a project and all was fine until I restarted mcuXpresso and then I have this error anytime I tried to build my project. I tried to restart MCU, clean the project, rebuild, I always end up with this error and I have no idea why

Error while creating linker scriptError while creating linker script

 

Tags (1)
0 Kudos
1 Solution
2,564 Views
abnxpweb
Contributor III

Double check the name of your memory regions (in the Memory Configuration Editor) against the values in the "Extra linker script input sections" fields. It looks to me like you probably have a mismatch.

If you use the dropdown in the "Extra linker script input sections", the IDE displays the available set of memory region names, at that point in time. But if you then edit the memory region names, things can get out of step unless you reselect.

Hope this helps!

View solution in original post

7 Replies
2,589 Views
DridriLaBastos
Contributor I

I haven't done any changes to the project settings, the only things I've done is adding files to compile and include path. I do this from a base project, both the base project and the project I am working on have the same linker configuration :

DridriLaBastos_0-1617094373568.png

 

The base project compiles without troubles, the new one was fine until I added a source path and this error happens. I tried to delete the source files I added but it doesn't remove the error

0 Kudos
2,580 Views
converse
Senior Contributor V

I’d suggest create a new project and copy your source files across intot the new project. 

0 Kudos
2,573 Views
DridriLaBastos
Contributor I

This probably what I will have to do. I don't have this problem when I compile in RELEASE mode, and in debug, there is a linker file that is not correctly created: two sections `.TEXT` are created  and the second one is not properly formated: I have those two lines at the end of the file MIMXRT1064_S2OPC_Debug.ld:

.text : ALIGN(4)
    {

and the `SECTIONS` block is not properly closed

0 Kudos
2,565 Views
abnxpweb
Contributor III

Double check the name of your memory regions (in the Memory Configuration Editor) against the values in the "Extra linker script input sections" fields. It looks to me like you probably have a mismatch.

If you use the dropdown in the "Extra linker script input sections", the IDE displays the available set of memory region names, at that point in time. But if you then edit the memory region names, things can get out of step unless you reselect.

Hope this helps!

2,546 Views
DridriLaBastos
Contributor I

It was that, the section names were not the same, I don't why I never touche memory in this project, I only add source path and include path

0 Kudos
2,595 Views
abnxpweb
Contributor III

Sounds like you have a problem with whatever entries you have got in the "Extra linker script input sections"  field of the IDE's Managed Linker Script setup. Check section 17.13.1 "Placing code and data into different Memory Regions" of the MCUXpresso IDE v11.3.0 User Guide:

abnxpweb_0-1617087330641.png

Hope this helps!

 

0 Kudos
2,607 Views
converse
Senior Contributor V

Have you changed your memory map recently? If so, try reverting it.

0 Kudos