Here is where I’ll be uploading builds of AVR-GCC for Windows 32 and 64 bit, which will also include Binutils, AVR-LibC, AVRDUDE and Make. I’ll be trying to keep the builds up to date with the latest tool releases when I can.
The binaries are built from source on an Arch Linux virtual machine with MinGW, apart from AVRDUDE where the pre-built binary was obtained from the official download area. Both 32 bit and 64 bit Windows binaries are provided. There’s probably no benefit from using the 64 bit stuff, but all the cool kids are doing it so why not.
A bash script for building AVR-GCC, AVR-Binutils and AVR-LibC from source is also provided below, making it super easy to build these tools for yourself.
avr-gcc-7.1.0-x64-mingw.zip (50.73 MB)
AVG-GCC 7.1.0 Windows x64 (64 bit)
Downloaded 324 times
avr-gcc-7.1.0-x86-mingw.zip (48.49 MB)
AVG-GCC 7.1.0 Windows x86 (32 bit)
Downloaded 162 times
Upgrading the Arduino IDE
Upgrading the Arduino IDE to AVR-GCC 7.1.0 is pretty easy, though there could be some incompatibilities with certain libraries. I’ve only tested this with Arduino 1.8.2.
- Download and extract one of the downloads above
- Navigate to your Arduino IDE folder
- Go to hardware/tools
- Move the avr folder somewhere else, like to your desktop (renaming the folder won’t work, Arduino has some auto-detect thing which sometimes gets confused)
- Move the extracted folder from earlier to the tools folder and rename it to avr
- Copy the builtin_tools_versions.txt file and etc folder from the old avr folder to the new one
- Done! Open up the Arduino IDE, load up the Blink example, upload it to your Arduino and make sure the LED is blinking!
When building for Windows there seems to be a problem with INT8_MAX and some other things being undefined in /gcc/config/avr/avr.c. Adding ‘#include <stdint.h>’ doesn’t fix it, but manually defining the values does the trick. The build script below includes the fix in the fixGCCAVR() function.
This build script will install the required packages, create directories and build the tools from source. This should work on Debian 8, Ubuntu 16.04, CentOS 7 and Arch.
Building takes about 30 minutes on an Arch Linux virtual machine with 4 cores i5 2500K @ 4GHz and 2GB RAM.