Another AArch64 Linux musl build fix attempt
After testing more thoroughly on my box, it turned out that the libgcc linking workaround should indeed fix our build errors, but on CI that did not happen because the `RUSTFLAGS` environment variable is set, which takes precedence over any configuration at `.cargo/config.toml`. Therefore, let's also add the workaround to `RUSTFLAGS` on the CI workflow definition. This should be a satisfactory enough stopgap solution that does not require ourselves to be pinned to a specific nightly or drop these builds until https://github.com/rust-lang/rust/issues/128401 is sorted out.
This commit is contained in:
parent
e2d58c112b
commit
1bb7109804
2 changed files with 8 additions and 1 deletions
|
|
@ -16,4 +16,9 @@ linker = "aarch64-linux-musl-gcc"
|
|||
# user-visible impacts on the final executables. See:
|
||||
# https://github.com/rust-lang/rust/issues/46651
|
||||
# https://github.com/rust-lang/compiler-builtins/issues/201
|
||||
# https://github.com/rust-lang/rust/issues/128401 (the issue most relevant to
|
||||
# our observed failures)
|
||||
# Note that these flags are not enforced on CI because CI overrides them through
|
||||
# the RUSTFLAG environment variable. Check out the CI workflow definition file at
|
||||
# .github/workflows/oxipng.yml for more info
|
||||
rustflags = ["-Clink-args=-lgcc"]
|
||||
|
|
|
|||
4
.github/workflows/oxipng.yml
vendored
4
.github/workflows/oxipng.yml
vendored
|
|
@ -55,7 +55,9 @@ jobs:
|
|||
|
||||
env:
|
||||
CARGO_BUILD_TARGET: ${{ matrix.target }}
|
||||
RUSTFLAGS: -Zlocation-detail=none
|
||||
# Hopefully temporary workaround for https://github.com/rust-lang/rust/issues/128401
|
||||
# See the comments for similar rustflag settings at .cargo/config.toml for more context
|
||||
RUSTFLAGS: ${{ matrix.target == 'aarch64-unknown-linux-musl' && '-Zlocation-detail=none -Clink-args=-lgcc' || '-Zlocation-detail=none' }}
|
||||
|
||||
steps:
|
||||
- name: Checkout source
|
||||
|
|
|
|||
Loading…
Reference in a new issue