Code:
avr-gcc -o test.elf main.c -Os -DF_CPU=1000000UL -mmcu=atmega8 -std=gnu99
zum bauen und um daraus ne hex zu machen
Code:
avr-objcopy -O ihex test.elf test.hex
Und noch ein paar infos
Code:
$avr-gcc --version
avr-gcc (GCC) 4.5.3
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$avr-objcopy --version
GNU objcopy (GNU Binutils) 2.20.1.20100303
Copyright 2009 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) any later version.
This program has absolutely no warranty.
Hoffe das hilft.