Closed
Description
Checklist
- I've looked through the issues and pull requests for similar reports
Describe your issue
The toolchain used in the freebsd images appears to be broken. I managed to reduce the test case basically down to just:
$ docker pull ghcr.io/cross-rs/x86_64-unknown-freebsd:0.2.4
$ docker run -it ghcr.io/cross-rs/x86_64-unknown-freebsd:0.2.4 bash
$ echo "int banana(void) { return 0; }" | x86_64-unknown-freebsd12-gcc -xc - -c -o chaenomeles.o
$ x86_64-unknown-freebsd12-gcc-ar cq mango.ar chaenomeles.o; echo $?
x86_64-unknown-freebsd12-gcc-ar: Cannot find plugin 'liblto_plugin.so'
1
This in practice causes crates such as cc
fail to package the built objects into an .a
in crates’ build.rs scripts.
What target(s) are you cross-compiling for?
i686-unknown-freebsd, x86_64-unknown-freebsd
Which operating system is the host (e.g computer cross is on) running?
- macOS
- Windows
- Linux / BSD
- other OS (specify in description)
What architecture is the host?
- x86_64 / AMD64
- arm32
- arm64 (including Mac M1)
What container engine is cross using?
- docker
- podman
- other container engine (specify in description)
cross version
cross 0.2.4
Example
No response
Additional information / notes
The closest relevant thing I can find on the internet is https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81326. Curiously we are already building the toolchain with --disable-lto
flag, so it might be a bug in gcc itself?