[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [avr-libc-dev] RE: [bug #26365] Better PROGMEM_FAR support

From: Stu Bell
Subject: RE: [avr-libc-dev] RE: [bug #26365] Better PROGMEM_FAR support
Date: Wed, 20 May 2009 08:28:07 -0600

> > This one seems more suited to a custom linker script for a 
> particular 
> > users' application.
> > 
> A section defined in this way results in absolutely no 
> penalty or any other problem for programs which don't use the 
> _far facilities. In other words, there are is no reason in 
> not doing this in the standard linker scripts - except that 
> the new linker scripts have to be created. And that's easy, 
> unless I am overlooking some pitfall. 
> I have no idea how are the linker scripts constructed - are 
> they generated in some way, or hand crafted?

There is a set of 5 standard linker scripts per AVR architecture, see
<WINAVR>\avr\lib\ldscripts.  The reason why there are 5 different
scripts per architecture is documented in the FAQ, #28.  Architectures
are described in the AVR-libc manual under the Using the GNU Tools
section (http://www.nongnu.org/avr-libc/user-manual/using_tools.html).

All of the scripts were hand generated.  You can modify or create your
own (I have!).  Look at
http://sourceware.org/binutils/docs/ld/Scripts.html#Scripts for
instruction on linker scripts.  When I did my script I started with the
standard script for my architecture (avr6.x) and went from there.  Of
course, if you use your own linker script, you should store it somewhere
other than under <WINAVR>! (duh!)

Hope this helps!

Best regards, 

Stu Bell 
DataPlay (DPHI, Inc.) 

reply via email to

[Prev in Thread] Current Thread [Next in Thread]