This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

reference to archive member in linker script?


Is it possible to specify a archive member with a SECTIONS description in a linker script?

For example, I'd like to place a few functions (section(s) of a module) together to avoid icache thrashing or to limit the number of
page faults for sequence of function calls, etc.


SECTIONS {
...

 SPECIAL  ALIGN ( 4096) : {
 libc.a(malloc.o .text)
 libc.a(sprintf.o .text)
libz.a(inflate.o .text)
}

.... }

The linked email from Nick Kelsey offered a patch to allow libraries to be specified, but using this syntax has the effect
of the library not getting linked in (unresolved symbols), and anyway, isn't quite what I'm looking for. I can
get what I need if I manually extract the needed .o files, and insert them into
the appropriate place in my linker script. I'm just hoping to avoid that step.


Thanks, JB

http://www.cygwin.com/ml/binutils/2004-02/msg00040.html


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]