This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linker warning: "no matching section" when trying to place memcpy from libc.a in output section

I would like to place some functions (e.g. memcpy) from libc.a in a special output section to be placed in fast memory. However, the linker always gives a "warning: no matching section" message for that line of the linker command file. 

I can see from our map file that we are linking in the "text:memcpy" section from "memcpy64.obj" of "rts64plus_elf.lib".

I think the following should work:

.fast_rts > SL2RAM

{

     -lrts64plus_elf.lib<memcpy64.obj> (.text:memcpy)

}

But it gives the above warning and doesn't place the function properly. I've tried other variants without success.

Please advise.

Thanks.

 

 

  • My guess is some other linker command file line like ...

    .text > RAM

    is picking up this .text input section.  Inspect your map file and search for "memcpy64.obj".  That should show you which output section contains it.  You probably need to move these lines ...

    Anthony Joch said:

    .fast_rts > SL2RAM

    {

         -lrts64plus_elf.lib<memcpy64.obj> (.text:memcpy)

    }

    earlier into your link command file.

    Thanks and regards,

    -George