Error: "avr-g++: cannot execute binary file"

I just have Arduino1.0.4 installed on my Raspberry Pi. I wrote program for Arduino Uno originally with Windows arduino022. With new installed Windows version of Arduino1.0.4 the program verifies ok but Raspberry Arduino1.0.4 gives me an error message so i think the problem is on my Linux installation, probably :fearful: Message:

Error compiling:
/home/pi/arduino-1.0.4/hardware/tools/avr/bin/avr-g++: line 3: /home/pi/arduino-1.0.4/hardware/tools/avr/bin/../bin.gcc/avr-g++: cannot execute binary file
/home/pi/arduino-1.0.4/hardware/tools/avr/bin/avr-g++: line 3: /home/pi/arduino-1.0.4/hardware/tools/avr/bin/../bin.gcc/avr-g++: Success
/home/pi/arduino-1.0.4/hardware/tools/avr/bin/avr-g++ returned 126

I'm a newbie with Linux so i have no glue what's the problem. Please give me a good glue :~

Installation instructions i followed: http://raspberrypi.homelabs.org.uk/raspberrypi-the-arduino-development-tool/

I found a working solution from another forum. Thanks for watching :grin:

http://www.raspberrypi.org/phpBB3/viewtopic.php?f=37&t=18183

ok well I seem to have solved the problem by renaming arduino-1.0.1/hardware/tools/avr/bin to arduino-1.0.1/hardware/tools/avr/bin_old

Apparently this forces Arduino to compile using the system avr routines instead of the ones installed with Arduino.

Hopefully this helps someone else with the same problem.