init
[CYBERHEART] / make
1 #!/bin/bash
2
3 targetProjectFile=heart
4 AVRGCC=avr-gcc
5 #AVRGCC=/usr/local/avr/bin/avr-gcc
6 #AVRGCC=/home/dmitry/Bin/avr8-gnu-toolchain-linux_x86_64/bin/avr-gcc
7
8
9 # export DEFINES="-mmcu=attiny10 -DF_CPU=12000000UL -DBOARD=1 -fno-strict-aliasing"
10 export DEFINES="-mmcu=attiny10 -DBOARD=1 -fno-strict-aliasing -Wattributes"
11
12 # export PATH=$PATH:/usr/local/avr/bin
13 # export PATH=$PATH:/home/dmitry/Bin/avr8-gnu-toolchain-linux_x86_64/
14
15 rm *.hex *.elf
16
17 $AVRGCC $DEFINES -Wall -O1 -std=gnu99 -o $targetProjectFile.o -c $targetProjectFile.c
18 $AVRGCC $DEFINES -Wl,-Map=$targetProjectFile.map $targetProjectFile.o  -o $targetProjectFile.elf
19 avr-objcopy -O ihex $targetProjectFile.elf $targetProjectFile.hex
20
21 echo "Compilatoin done"
22 exit
Contact me: dev (at) shalnoff (dot) com
PGP fingerprint: A6B8 3B23 6013 F18A 0C71 198B 83D8 C64D 917A 5717