I try to communicate with my Arduino clone (Elegoo Uno R3) from Arduino IDE (v1.8.4 installed by
dnf from repos) at Fedora 27. Compiling and upload of normal example code works well. However, as I try to start any serial communication (e.g. for debug), the compiler fails returning following segfault:
"/usr/bin/avr-gcc" -Os -g -flto -fuse-linker-plugin -Wl,--gc-sections -mmcu=atmega328p -o "/tmp/arduino_build_407070/AnalogReadSerial.ino.elf" "/tmp/arduino_build_407070/sketch/AnalogReadSerial.ino.cpp.o" "/tmp/arduino_build_407070/../arduino_cache_983152/core/core_arduino_avr_uno_1621df717313d057c92202babd71649a.a" "-L/tmp/arduino_build_407070" -lm lto1: internal compiler error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See <https://bugzilla.redhat.com/> for instructions. lto-wrapper: fatal error: /usr/bin/avr-gcc returned 1 exit status compilation terminated. /usr/lib/gcc/avr/6.3.0/../../../../avr/bin/ld: error: lto-wrapper failed collect2: error: ld returned 1 exit status exit status 1 Error compiling for board Arduino/Genuino Uno.
I found similar issue here https://github.com/sudar/Arduino-Makefile/issues/486 However, that solution deals with Arduino-Makefile software that is little bit complex for me.
I would appreciate any help either how to solve the segfault itself, or how to easily use Arduino-Makefile (I would like to compile from Arduino IDE or any user-friendly IDE).