[Top][All Lists]

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

Re: [avr-gcc-list] A few basic doubts regarding installing AVR-GCC on Fe

From: Bernard Fouché
Subject: Re: [avr-gcc-list] A few basic doubts regarding installing AVR-GCC on Fedora 9
Date: Mon, 01 Sep 2008 09:53:07 +0200
User-agent: Thunderbird (Windows/20080708)

Hi Eshwaran.

Here is what I did to have avr-gcc and friends on Fedora 9:

- Get WinAvr (20080610) : http://sourceforge.net/project/showfiles.php?group_id=68108

- Get GNU Binutils (2.18):  <http://sources.redhat.com/binutils/>

- Get GCC (4.3.0) : <http://gcc.gnu.org/>

- Get avr-libc: <http://savannah.nongnu.org/projects/avr-libc>

- Get avrdude: <http://savannah.nongnu.org/projects/avrdude/>

WinAvr has all the patches that Eric Weddington used to build a working WinAvr. These patches are mandatory to get a fully working toolchain and using WinAvr as a patch repository is much easier than doing the 'patch hunt' yourself. (Once you get the patches, WinAvr won't have any more use for F9.)

Apply these patches to the corresponding project (gcc patches for gcc, etc). Use the '-p0' option when you run the 'patch' command for each patch.

Define where you want to have the binaries, libs and other files resulting from the different compilations. For instance '/home/avr'.

- Compile binutils (go into the binutils top directory):

$ ./configure --target=avr --prefix=/home/avr
$ make maybe-configure-bfd
$ pushd bfd
$ make headers
$ popd
$ make all install

- Compile GCC (go into the gcc top directory):

$ mkdir obj
$ cd obj
$ ../configure --target=avr --prefix=/home/avr --disable-nls --enable-languages=c
$ make
$ make install

- Compile avr-libc (go into the top avr-libc directory):

$ ./configure --build=`./config.guess` --host=avr --prefix=/home/avr
$ make
$ make install

- Compile avrdude (go into the top avrdude directory):

$ ./configure --prefix=/home/avr
$ make
$ make install

(these are from notes I wrote when I last built the toolchain, I hope I did not miss something since I was not brave enough to recompile everything before posting this answer :) )

You may also need some other tools like avarice...

Once everything is compiled, add '/home/avr/bin' in your PATH and you should be able to compile a project for the AVR.

Hope it helps!


Eshwaran Vijaya Kumar wrote:
  I am a newbie to both AVR and AVR-GCC. I am trying to find out what
are the lastest versions of GCC that I should be using:
   The AVR Lib C user manual suggests that I use the latest version of
GCC (4.3.2 is the latest ). The manual also suggests that I have to
patch the latest version from
in order for everything to work properly. I then went to the
AVRfreaks.net GCC forum where I see a list of patches where the
patches specifically refer to GCC 4.2.2?
Can some one clarify which version I am supposed to be using? I am
using Fedora 9 with GCC 4.3.0 already installed.
Thanks in advance.

reply via email to

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