Go Down

Topic: Intermitent upload/compilation failure (Read 713 times) previous topic - next topic


I downloaded the arduino IDE from the windows store on my laptop (running windows 10 64 bit). When I write a program and then press Verify or upload, I get the following error.

Linking everything together...
Code: [Select]
"C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.6.11.0_x64__mdqgnx93n4wtt\hardware\tools\avr/bin/avr-gcc" -w -Os -flto -fuse-linker-plugin -Wl,--gc-sections -mmcu=atmega328p  -o "C:\Users\stoil\AppData\Local\Temp\build74329c6364bb960745fbaa7ff58b3b5b.tmp/inductor_bell.ino.elf" "C:\Users\stoil\AppData\Local\Temp\build74329c6364bb960745fbaa7ff58b3b5b.tmp\sketch\inductor_bell.ino.cpp.o" "C:\Users\stoil\AppData\Local\Temp\build74329c6364bb960745fbaa7ff58b3b5b.tmp/core\core.a" "-LC:\Users\stoil\AppData\Local\Temp\build74329c6364bb960745fbaa7ff58b3b5b.tmp" -lm
collect2.exe: error: ld returned 5 exit status

exit status 1
Error compiling for board Arduino/Genuino Uno.

The strange thing is that if I press the same button (wether if it was verify or upload) again without changing anything it works. Sometimes it's n the first try, sometimes it's one the fifth (or anything in between those so far).

It doesn't matter what code I write as this is reproduced with other scripts as well.

Any idea what the problem might be?


Enable verbose compile in settings and post the output from a failure.
ATtiny core for 841+1634+828 and x313/x4/x5/x61/x7/x8 series Board Manager:
ATtiny breakouts (some assembled), mosfets and awesome prototyping board in my store http://tindie.com/stores/DrAzzy


This is what I get. As I said, it's intermittent, but frequently enough to be a problem.


There was another report of the same issue using the Windows Store version of the Arduino IDE:
but OP disappeared so I wasn't able to look into the issue further. I'd recommend installing the standard version of the Arduino IDE to see if that solves the issue.

Is 1.6.11 the most recent version available via the Windows Store?


I'll try that when I get back from work.

And yes, 1.6.11 is the latest available from the windows store.

It would really help if I knew what "collect2.exe: error: ld returned 5 exit status" actually means.


1.6.11 is the latest available from the windows store.
How stupid that they don't have the most recent version. We're on 1.6.13 already, 1.6.11 was released over 3 months ago.

It would really help if I knew what "collect2.exe: error: ld returned 5 exit status" actually means.
ld is the gcc linker. Usually we see this intermittent error when people are using recent versions of the Arduino IDE with Windows XP but I've only seen the one other report of it on Windows 10.


ld is the gcc linker.
Would this have something to do that I have a bunch of other IDEs (Visual studio, IntelliJ) installed? Those did require me to install cpp redistributals to work.


I don't think so because the Arduino IDE includes and uses its own copy of avr-gcc so it shouldn't be affected by any other versions you have installed unless those other IDEs modify your Arduino IDE installation.


Well I installed the non-store version (1.6.13) and it seems to work perfectly. I'll keep an eye out if it fails in the future with the same error.

Go Up