3 targetProjectFile=lightstick
7 export DEFINES="-mmcu=attiny25 -DF_CPU=8000000UL -DBOARD=1 -fno-strict-aliasing"
9 # export PATH=$PATH:/usr/local/avr/bin
13 # /usr/local/avr/bin/avr-gcc
15 avr-gcc $DEFINES -Wall -O1 -std=gnu99 -o $targetProjectFile.o -c $targetProjectFile.c
16 avr-gcc $DEFINES -Wl,-Map=$targetProjectFile.map $targetProjectFile.o -o $targetProjectFile.elf
17 avr-objcopy -O ihex $targetProjectFile.elf $targetProjectFile.hex
19 avr-size $targetProjectFile.hex
21 echo "Compilatoin done"