buserror / simavr

simavr is a lean, mean and hackable AVR simulator for linux & OSX
GNU General Public License v3.0
1.56k stars 365 forks source link

Simavr default target cannot be built with newer gcc versions #195

Closed hovercraft-github closed 7 years ago

hovercraft-github commented 7 years ago

Definition of the AVR_MCU_VCD_SYMBOL macro contains a bug, which older gcc versions skip, but the newer catch. For example with gcc (GCC) 6.3.1 20161221 (Red Hat 6.3.1-1) : atmega88_uart_echo.c:34:23: error: initialization of flexible array member in a nested context { AVR_MCU_VCD_SYMBOL("UDR0"), .what = (void*)&UDR0, }, The problem is that an array of avr_mmcu_vcd_trace_t initialized and its elements have different sizes.

hovercraft-github commented 7 years ago

Oops.. This is of course avr-gcc, sorry ! avr-gcc (Fedora 6.2.0-1.fc25) 6.2.0

spoorcc commented 7 years ago

Probably same as #131

hovercraft-github commented 7 years ago

@spoorcc : you are right - this is the same. Closing.