Skip to content

ci: name the bintest build in ci/gcc-clang - #7140

Merged
matz merged 1 commit into
mruby:masterfrom
takumin:ci-name-bintest-build
Aug 14, 2026
Merged

ci: name the bintest build in ci/gcc-clang#7140
matz merged 1 commit into
mruby:masterfrom
takumin:ci-name-bintest-build

Conversation

@takumin

@takumin takumin commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

build_config/ci/gcc-clang.rb defines three builds, and two of them carry a
name. The middle one is written as MRuby::Build.new do |conf|, so
MRuby::Build#initialize gives it the default host, and every line CI prints
for it reads >>> Test host <<<.

That name says nothing about the build. What separates it from its two siblings
is that it is the only one in the file that calls enable_bintest, and the
only one that adds mruby-bin-debugger back after the full-core gembox
leaves it out. This names it bintest after that coverage, so the CI log and
the build directory both say which of the three is speaking.

-MRuby::Build.new do |conf|
+MRuby::Build.new('bintest') do |conf|

Why the host name is free to give up here

host is load bearing elsewhere, so it is worth spelling out that no part of
it applies to this file.

  • MRuby::Build#mrbcfile falls back to the mrbc of a host target only for
    a build that is not itself host. All three builds here are MRuby::Build
    rather than MRuby::CrossBuild, and each pulls mruby-bin-mrbc in through
    full-core, so every one of them already has its own.
  • install_prefix sends a non host build to <prefix>/mruby/<name>, and
    define_installer_if_needed defines an installer into MRUBY_ROOT/bin only
    when host? answers true. Both run under rake install.
  • rake clean removes mrbtest from MRUBY_ROOT/bin for the host target.

The workflows that read this config run rake -m test:run:serial
(build.yml) and rake test (coverage.yml). Neither installs nor cleans, and
run_test and run_bintest reach the binaries through build_dir and the
BUILD_DIR environment variable rather than through bin/, so none of the
above is on the path CI takes.

The one real cost is for a developer who points MRUBY_CONFIG at this config
by hand: the bin/ entries stop appearing, because only a host build
installs them. build_config/default.rb is the config for that use, and this
file exists to be read by the two workflows above.

build_config/ci/msvc.rb is left alone. It holds a single build, so there is no
sibling for a name to tell it apart from, and the default reads fine there.

Verification

MRUBY_CONFIG=ci/gcc-clang rake -m test on Linux with gcc:

run result
Test cxx_abi 2269 total, 2259 OK, 0 KO, 0 crash, 10 skip
Test full-debug 2269 total, 2259 OK, 0 KO, 0 crash, 10 skip
Test bintest 2268 total, 2266 OK, 0 KO, 0 crash, 2 skip
Bintest bintest 116 total, 116 OK, 0 KO, 0 crash

The bintest run is the one the rename could have broken, since it resolves
mrdb and the other binaries at run time; it stays green.

Summary by CodeRabbit

  • Chores
    • Explicitly named the binary test build configuration for clearer build identification.

`build_config/ci/gcc-clang.rb` defines three builds. Two carry a name,
`full-debug` and `cxx_abi`, and the middle one is written without one, so
`MRuby::Build#initialize` gives it the default `host`. CI prints
`>>> Test host <<<` for it, which says nothing about what separates it from the
other two: it is the only build in the file that calls `enable_bintest`, and
the only one that adds `mruby-bin-debugger` back after the `full-core` gembox
leaves it out. That coverage is what it alone carries, so `bintest` is the name
it takes here.

Nothing in the file needs the build to be called `host`. All three are
`MRuby::Build` rather than `MRuby::CrossBuild`, and each pulls `mruby-bin-mrbc`
in through `full-core`, so no target falls back to the `mrbc` of a `host` build
in `MRuby::Build#mrbcfile`. The name reaches three other places:
`install_prefix`, the installer that `define_installer_if_needed` defines only
when `host?` answers true, and the `mrbtest` that `rake clean` removes from
`MRUBY_ROOT/bin`. The workflows that read this config run
`rake -m test:run:serial` and `rake test`, and neither installs nor cleans, so
none of the three fires.

What the rename costs is the `bin/` entries a developer gets from pointing
`MRUBY_CONFIG` at this config by hand. `build_config/default.rb` is the config
for that; this one is read by `.github/workflows/build.yml` and `coverage.yml`.

`build_config/ci/msvc.rb` keeps the default name. It holds a single build, with
no sibling for a name to tell it apart from.

`MRUBY_CONFIG=ci/gcc-clang rake -m test` passes: no failures in the three
mrbtest runs, and 116 of 116 in the bintest run.
@takumin
takumin requested a review from matz as a code owner August 13, 2026 16:50
@github-actions github-actions Bot added the build label Aug 13, 2026
@coderabbitai

coderabbitai Bot commented Aug 13, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 35cdf8e0-78a4-4910-b390-25be211043ff

📥 Commits

Reviewing files that changed from the base of the PR and between 3adb9e4 and 14d6e42.

📒 Files selected for processing (1)
  • build_config/ci/gcc-clang.rb

📝 Walkthrough

Walkthrough

The CI configuration gives the binary test build the explicit name bintest. Its toolchain, gems, compiler defines, and test settings remain unchanged.

Changes

Binary test build

Layer / File(s) Summary
Name binary test build
build_config/ci/gcc-clang.rb
The build changes from an unnamed MRuby::Build to MRuby::Build.new('bintest').

Estimated code review effort: 1 (Trivial) | ~2 minutes

Mergeability Score: ⚪ Minimal · up to 14d6e

This change only gives the CI bintest build a descriptive name, with the reported test and bintest runs remaining green; no actionable merge-blocking risk remains.

Suggested reviewers: matz

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes naming the bintest build in the specified CI configuration.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants