On Sunday 20 April 2008 01:28, Wouter van Gulik wrote: [...] > > ../../gcc/config/avr/libgcc.S:280: Error: illegal opcode movw for mcu > > avr3 [...] > This is because binutils 2.18 does not support avr architecture 35. > Use binutils 2.18.5 or more recent.
More exactly: this is because binutils 2.18 does not support the MOVW instruction with architecture 3. The simplest workaround (if you are not happy to install new binutils) is to add '-mall-opcodes': Replace into 'config/avr/avr.h' the string: #define ASM_SPEC "%{mmcu=avr25:-mmcu=avr2; mmcu=avr35:-mmcu=avr3; mmcu=avr31:-mmcu=avr3;mmcu=avr51:-mmcu=avr5;mmcu=*:-mmcu=%*}" to: #define ASM_SPEC "%{mmcu=avr25:-mmcu=avr2; mmcu=avr35:-mmcu=avr3 -mall-opcodes; mmcu=avr31:-mmcu=avr3;mmcu=avr51:-mmcu=avr5;mmcu=*:-mmcu=%*}" Regards, Dmitry. _______________________________________________ AVR-GCC-list mailing list AVR-GCC-list@nongnu.org http://lists.nongnu.org/mailman/listinfo/avr-gcc-list