Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
13 years ago

Custom Linker Script

Dear all,

I have to add an output section in the final binary called "EXTSec". Therefore, I modified the makefile to point to a linkerscript.lds. Then I copied the original likerscript.x contents, which is located in ./bsp folder, and pasted it into my linkerscript.lds. After that, I added the following output section

.EXTsec :

{

./obj/CRT1.o

} > SDRAM

As a result, I got the following error

./obj/CRT1.o: In function `Task_CRT1':

multiple definition of `Task_CRT1'

obj/CRT1.o CRT1.c:19: first defined here

collect2: ld returned 1 exit status

make: ***[App.elf] Error 1

I need to put all input sections in that object file at the same output section contiguously.

12 Replies