This is the mail archive of the crossgcc@sources.redhat.com mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


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: Linker script


On Thu, Jun 26, 2003 at 10:18:18AM +0200, Daniel Lidsten wrote:
> 
>     .text   0x5000  :      { _stext = .; *(.text*) *(.gnu.warning)
> *(.gnu.linkonce*) *(.init) } >  ram  _etext = .;  PROVIDE 
> 
> The text segment specifies where the end is in the variable _etext.
> 
> I need the above value to be place on a fixed location by something like
> this:
> 
> .TextEnd   0x004DFFFC :      { etext }


Daniel,

   Linker-defined symbols can be used in your source code, so would it
   perhaps be simpler to use _etext directly there?:

   crc = (unsigned long*)&_etext;

   Now you have a handle on the CRC, without intermediate steps.

   Hope this helps.

Regards,
Erik





------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com


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