Repository navigation
build(rspec): upgrade rb-sys and magnus for LLVM 22 and unpin ubuntu-24.04 (TRUNK-23633) - #1311
Merged
Merged
Conversation
…ubuntu-24.04 (TRUNK-23633) The ubuntu-26.04 runner image ships clang 20, 21 and 22, and clang-sys loads the newest libclang it finds, so bindgen ran against libclang 22. rb-sys 0.9.124's bindgen 0.69 then emits rb_data_type_struct (and rb_io_t) as opaque structs, and magnus fails to compile against Ruby 3.1's headers. rb-sys 0.9.125 moved rb-sys-build to bindgen 0.72, which generates the full structs (oxidize-rb/rb-sys#712, matsadler/magnus#174). - rb-sys 0.9.124 -> 0.9.130 (crate and rb_sys gem, so rb-sys-dock uses the 0.9.130 images); bindgen 0.69.5 -> 0.72.1 - magnus 0.8.2 -> 0.8.4 in the gem, context and test_report (patch releases; 0.8.4 requires rb-sys ^0.9.124 and fixes a $! crash) - Move ruby.yml's build job back to ubuntu-latest Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
😎 Merged successfully - details. |
acatxnamedvirtue
requested review from
TylerJang27,
dfrankland and
max-trunk
November 11, 2026 18:43
TylerJang27
approved these changes
Nov 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of TRUNK-23633
Why
GitHub's
ubuntu-latestmoved to 26.04, so #1300 pinned the rspec gem'sbuildjob toubuntu-24.04. On 26.04 the runner has clang 20, 21 and 22, and clang-sys loads the newest, libclang 22. rb-sys 0.9.124 ships bindgen 0.69, which can't handle LLVM 22 (oxidize-rb/rb-sys#712, matsadler/magnus#174). It maderb_data_type_structopaque (_address: u8), so magnus failed to compile against Ruby 3.1. Forcing libclang 21 or 20 built fine. rb-sys 0.9.125 and later use bindgen 0.72, which fixes it.What changes
rb-syscrate andrb_sysgem:=0.9.124→=0.9.130(bindgen 0.69.5 → 0.72.1). rb-sys-dock 0.9.130 images exist for all six release platforms.magnus: 0.8.2 → 0.8.4 in the gem,contextandtest_report. A patch release; 0.9.x has breaking API changes, so it stays on 0.8. magnus pulledrb-sys-env0.2.2 → 0.2.3.Cargo.lockfiles andGemfile.lockupdated.rake-compiler-dock1.11 → 1.12 came along with the gem.ruby.yml'sbuildjob back onubuntu-latest, and the pin's comment removed.release_ruby_gem.ymlalready ran onubuntu-latest.Testing
Run on an Ubuntu 26.04 host with clang 20, 21 and 22 installed, as on the runner, using ruby-builder's
ubuntu-26.04Rubies installed the waysetup-rubyinstalls them. Command:bundle exec rake test.--all-features) shows no new warnings.cargo fmt,trunk checkandtrunk fmtare clean.Not run locally: cross-compiling in the rb-sys-dock 0.9.130 images (
build-ruby-gem, the releasecross-gemjob). This PR's CI covers it.Known, out of scope: ruby-builder's 26.04 build of Ruby 3.2.11 fails in bindgen with
unknown type name 'bool', with either rb-sys version and on any libclang. Itsconfig.hlacksHAVE_STDBOOL_H, probably because GCC 15 built it as C23.BINDGEN_EXTRA_CLANG_ARGS=-std=gnu23works around it. Neither CI nor the release gems compile against that Ruby; only a source build with Ruby 3.2 on 26.04 would hit it.🤖 Generated with Claude Code