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]

RE: emitting "section start" and "section end" symbols in relocatable objects


On 15 May 2007 01:32, Prasad Boddupalli wrote:

> Is it possible to have the compiler or linker (if linking partially
> using -r option) generate symbols for the start address and end
> address of user defined sections in relocatable object files ?

  If they're only partially linked, there /is/ no start and end address yet.
You can find out the size of each section, but there's no meaning to asking
what addresses an unrelocated object belongs at.

> They seem to be generated for shared objects. For example, if there is
> a user defined section "set_modmetadata_set", then the symbols
> "__start_set_modmetadata_set" and "__stop_set_modmetadata_set" are
> automatically generated.

  Ah, yeh, but those symbols get relocated by ld.so at load time according to
where the data /actually/ ends up.

    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....


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