which C standard(s) does Microchip's avr-gcc support?

Go To Last Post
3 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I'd like to find out which C standards does Microchip's avr-gcc support. Looks like it goes up to C11. Is there a way other than trying different values for -std option?

 

user@Station:/opt/microchip/avr8-gnu-toolchain-linux_x86_64/bin$ ./avr-gcc --version
avr-gcc (AVR_8_bit_GNU_Toolchain_3.6.2_1759) 5.4.0

user@Station:/opt/microchip/avr8-gnu-toolchain-linux_x86_64/bin$ ./avr-gcc --help | grep standard
  -std=<standard>          Assume that the input sources are for <standard>

user@Station:/opt/microchip/avr8-gnu-toolchain-linux_x86_64/bin$ ./avr-gcc -std=c17
avr-gcc: error: unrecognized command line option '-std=c17'

user@Station:/opt/microchip/avr8-gnu-toolchain-linux_x86_64/bin$ ./avr-gcc -std=c99
avr-gcc: fatal error: no input files

user@Station:/opt/microchip/avr8-gnu-toolchain-linux_x86_64/bin$ ./avr-gcc -std=c11
avr-gcc: fatal error: no input files

 

 

 

This topic has a solution.
Last Edited: Fri. Feb 14, 2020 - 01:35 PM
This reply has been marked as the solution. 
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 1


The copy of the user manual that ships with it should show the standards it has support for.

 

EDIT: try:

C:\Program Files (x86)\Atmel\Studio\7.0\toolchain\avr8\avr8-gnu-toolchain\share\doc\gcc>Standards.html

and have a read through that. The copy on your hard drive should match the issued version of the compiler you have.

 

EDIT2: so....

 

Last Edited: Fri. Feb 14, 2020 - 11:06 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

PS so "14" is the latest.

 

(if you get a GCC 8 or 9 it would obvioulsy have later standards)