how to link a section in specific .o inside .a via linker script?
mat@lcs.mit.edu
mat@lcs.mit.edu
Fri Jan 12 19:26:00 GMT 2007
I am creating a linker script to place sections at exactly the
addresses I want them.
In a linker script it is easy to link in just a section from
a specific .o file, like this:
.text : { bar.o(.text) }
However, I want a specific section from a specific .o file that is
inside a specific .a file. Naively, given the textual format used to
describe archive members in -Map files, I hoped this would work:
.text : { /lib/libc.a(bar.o)(.text) }
But it doesn't parse. I can't seem to figure out a way to name just
this one section in that .o file in the archive.
Is this possible? Thanks!
-Mat
More information about the Binutils
mailing list