Closed wareya closed 6 months ago
I changed the runner from ubuntu-latest
(ubuntu 22) to ubuntu-24.04
and this error went away. I assume that rustc was somehow finding a version of libm from the ubuntu environment and then finding a version of glibc from the nix shell environment, which were incompatible.
Describe the Bug
I'm trying to make a fully static build of a project that depends on
inkwell
using a github actions runner, a nix shell, and thex86_64-unknown-linux-musl
rust target. Butlibinkwell_internals
triggers a linking failure because it's somehow linking a version oflibm
that linksglibc
instead of musl'slibc
.I can't tell if this is an issue with my own environment or not.
inkwell_internals
seems relatively simple and doesn't have abuild.rs
, so maybe it's a problem with one of the librariesinkwell_internals
is pulling in...? Or maybe it's an issue with how procedural macros don't use the--target
specified by Cargo, and I need to install more dependencies into my runner environment?inkwell_internals
is previously compiled as:For reproducibility reasons I'm targeting a specific inkwell git revision in Cargo.toml:
To Reproduce
Haven't reproduced locally, only in the cloud: https://github.com/wareya/konoran/actions/runs/9159087795/job/25178738603
The length of weird rust errors are because of the compiler failing to link
inkwell_internals
during compilation; open up the raw logs and ctrl+fextern crate inkwell_internals
.Expected Behavior
I should be getting weird symbol resolution errors at the low-level linking stage at the end of compilation, rather than an error about glibc.
LLVM Version (please complete the following information):
llvm 18, inkwell revision
5d5a531c765a6ad37aa6591c0287d0f9109fff62
Desktop (please complete the following information):
Ubuntu-based github actions runner