[Top][All Lists]

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

Re: [avr-gcc-list] 20020601 Libc AVR4/ATMega8 support?

From: Tony Mahar
Subject: Re: [avr-gcc-list] 20020601 Libc AVR4/ATMega8 support?
Date: Wed, 12 Jun 2002 00:11:50 -0400

Ok, some good news and some more issues.

Everything SEEMS to compile fine:

-------- begin --------
avr-gcc -c -g  -Os -Wall -Wstrict-prototypes -Wa,-ahlms=gcctest1.lst -mmcu=a
a8 -I. gcctest1.c -o gcctest1.o
avr-gcc  gcctest1.o  -Wl,-Map=gcctest1.map,--cref -mmcu=atmega8 -o
avr-objcopy -O avrobj -R .eeprom gcctest1.elf gcctest1.obj
avr-objcopy -O ihex -R .eeprom gcctest1.elf gcctest1.hex
elfcoff gcctest1.elf coff gcctest1.cof gcctest1.sym
cp coff/gcctest1.cof .
cp coff/*sym .
avr-objcopy -j
.eeprom --set-section-flags=.eeprom="alloc,load" --change-section
-lma .eeprom=0 -O ihex gcctest1.elf gcctest1.eep
avr-size gcctest1.elf
   text    data     bss     dec     hex filename
     98       0       0      98      62 gcctest1.elf
Errors: none
-------- end --------

The only issue I ran into was the avrfreaks general makefile... in their
make file they use elfcof to generate the cof and symbol files....

The original setup was this:
%.cof: %.elf
 $(ELFCOF) $< $(OUT) $@ $*.sym
 $(CP) $(OUT)\$@ .
 $(CP) $(OUT)\\*sym .
 $(CP) $(OUT)\\*S .

The setup i had to use (with cygwin now... not mingw)
%.cof: %.elf
        $(ELFCOF) $< $(OUT) $@ $*.sym
        $(CP) $(OUT)/$@ .
        $(CP) $(OUT)/*sym .
#       $(CP) $(OUT)/*S .

However in my case there never was a *S file in the coff subdirectory and
would cause an error to be detected by AVR Studio 3.54.  What should have
been there?

Also, after SUCESSFUL compile I get the following two dialog windows:

First dialog error window:
"Error: One or more source files cannot be found"
Second dialog error window:
"Error in Nordic Object file"

When trying to open the .cof file for debugging in AVR Studio 3.54 (may 8
build) an error dialog box opens up:
"Error in memory size"

I remember seeing in avrfreaks the guy who made this program had the same
problem... not quite sure why i'm having it now.

Opening up the hex file it is a great compile!  Debugging the .hex file
produces the desired simulation.


----- Original Message -----
From: "Lee Davies" <address@hidden>
To: "Tony Mahar" <address@hidden>; "Marek Michalkiewicz"
Cc: <address@hidden>
Sent: Tuesday, June 11, 2002 3:45 AM
Subject: Re: [avr-gcc-list] 20020601 Libc AVR4/ATMega8 support?

> What version of GCC tools do you have ???
> I've tried everywhere to find a Win32 GCC build with MEGA8 support with no
> joy. Do I just need a few files (crtm8.o, io8m.h, etc,...) ??
> > > i checked the AVR-LIBC directory and there indeed is no crtm8.o, but
> plenty of others like
> >
> > Check the avr4 subdirectory, you should see crtm8.o there (as well as
> > libc.a and libm.a).  You should also see the avr3 and avr5 subdirs.
> > Compiling a simple program with -mmcu=atmega8 works for me.  Perhaps
> > there is some problem with multilib support when building on win32?
> >
> > Marek
> avr-gcc-list at http://avr1.org

avr-gcc-list at http://avr1.org

reply via email to

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