avr-gcc-ar fails to run
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Raspbian |
New
|
Undecided
|
Unassigned |
Bug Description
Fresh raspbian lite (April 2017) with apt-get install gcc-avr (1:4.8.
```
pi@raspberrypi:~ $ avr-gcc-ar --help
avr-gcc-ar: Cannot find plugin 'liblto_plugin.so'
```
Based on strace, avr-gcc-ar finds the liblto_plugin.so but doesn't recognize it as it doesn't have execute access. Giving execute access to the library (which is behind a symlink) provides the following problem:
```
pi@raspberrypi:~ $ sudo chmod a+x /usr/lib/
pi@raspberrypi:~ $ avr-gcc-ar --help
sorry - this program has been built without plugin support
```
avr-gcc-ar attempts to execute avr-ar, which doesn't support the --plugin option.
Might be an upstream bug, but I don't have a pure raspbian jessie installation to test this with.
gcc works around the first issue by specifically passing R_OK to the find_a_file function responsible for locating the liblto. This was changed in 2013: https:/
The second issue feels more a problem of the binutils/gcc compatibility in raspbian/jessie.
System: Linux raspberrypi 4.4.50+ #970 Mon Feb 20 19:12:50 GMT 2017 armv6l GNU/Linux
Libc package: 2.19-18+deb8u7