Skip to content

Comments

fix(ci): use ubuntu:22.04 for RISC-V cross-compilation#376

Merged
marc0der merged 1 commit intosdkman:masterfrom
gounthar:fix/riscv64-cross-compilation
Feb 7, 2026
Merged

fix(ci): use ubuntu:22.04 for RISC-V cross-compilation#376
marc0der merged 1 commit intosdkman:masterfrom
gounthar:fix/riscv64-cross-compilation

Conversation

@gounthar
Copy link
Contributor

@gounthar gounthar commented Feb 7, 2026

Summary

  • Use ubuntu:22.04 container instead of ubuntu:20.04 for the riscv64gc-unknown-linux-gnu build target in the release workflow
  • Fixes linker error unsupported ISA subset 'z' caused by old binutils in ubuntu:20.04 not recognizing newer RISC-V ISA extensions (zaamo, zalrsc, zca, zcd, zmmul) emitted by the Rust stable compiler
  • Other Linux targets (x86_64, i686, aarch64) remain on ubuntu:20.04 for maximum glibc compatibility

Context

The release workflow run #21783422096 failed on the Build riscv64gc-unknown-linux-gnu job.

Ubuntu 22.04 ships gcc-12-riscv64-linux-gnu with binutils >= 2.38 which supports these extensions.

Test plan

  • PR checks (fmt, check, test) pass on ubuntu/windows/macos
  • Actual cross-compilation verified by triggering the Release workflow (manual dispatch)

The ubuntu:20.04 container ships gcc-9-riscv64-linux-gnu with binutils
that cannot parse newer RISC-V ISA extension strings (zaamo, zalrsc,
zca, zcd, zmmul) emitted by the Rust stable compiler, causing linker
error "unsupported ISA subset 'z'".

Ubuntu 22.04 ships gcc-12-riscv64-linux-gnu with binutils >= 2.38
which supports these extensions. Only the RISC-V entry changes; other
Linux targets keep ubuntu:20.04 for maximum glibc compatibility.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@marc0der marc0der merged commit 59e3b69 into sdkman:master Feb 7, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants