scx_cake: bump version + scx_cargo to fix crates.io install#3604
Open
rrnewton wants to merge 1 commit into
Open
scx_cake: bump version + scx_cargo to fix crates.io install#3604rrnewton wants to merge 1 commit into
rrnewton wants to merge 1 commit into
Conversation
Commits 97cf25f ("scx_cake: fix lib paths") + 11cb5f2 ("scx_cake: bump version") landed the symlink-based path fix for scx_cake — the same pattern as scx_cosmos commit 605c7d2. That fixed the original `clang: error: no such file or directory: '../../../lib/arena.bpf.c'` that blocked installing scx_cake 1.1.1 from crates.io. However scx_cake 1.1.2 still cannot install from crates.io. Unlike scx_cosmos (which only bundles pmu.bpf.c), scx_cake bundles sdt_alloc.bpf.c and sdt_task.bpf.c, both of which now use the scx_err_loc/scx_err/scx_out_loc macros introduced in commit 73b4543 ("lib: move allocators to BPF streams reporting", 2026-05-13). Those macros live in scheds/include/lib/alloc/bpf_helpers_local.h, which ships inside the scx_cargo crate's bpf_h tarball. But the scx_cargo crate on crates.io is still 1.1.1 (published 2026-05-13, before the streams refactor), so its bundled bpf_helpers_local.h lacks those macros — making any cake 1.1.2 install from crates.io fail with: src/bpf/lib/sdt_alloc.bpf.c:45:2: error: call to undeclared function 'scx_err_loc' Fix this by re-publishing scx_cargo with the current (post-streams) bpf_h, and bumping cake to consume it: * rust/scx_cargo: 1.1.1 -> 1.1.2 (no code change, picks up the new bpf_helpers_local.h via the bpf_h -> ../../scheds/include symlink that gets resolved at `cargo package` time) * scheds/rust/scx_cake: 1.1.2 -> 1.1.3, build-dep scx_cargo "1.1.1" -> "1.1.2" Validation ---------- Local validation simulates the post-publish state without actually publishing: 1. cargo package -p scx_cargo -p scx_cake --no-verify # both build 2. extract both tarballs side by side under /tmp/cake-install-sim/ 3. in extracted scx_cake-1.1.3/, inject [patch.crates-io] scx_cargo = { path = "../scx_cargo-1.1.2" } 4. cargo build # succeeds: scx_err_loc resolves via the new bpf_h # tar that scx_cargo 1.1.2 ships (Step 3 is the post-extract simulation of how cargo install will resolve scx_cargo 1.1.2 from crates.io once published — the contents inside the extracted tarballs are exactly what the registry would serve.) Release ordering: scx_cargo 1.1.2 must be published before scx_cake 1.1.3 so cargo can resolve the new build-dep version. Signed-off-by: Ryan Newton <rrnewton@gmail.com>
rrnewton
added a commit
to rrnewton/dev-sched-test
that referenced
this pull request
May 27, 2026
tg fix-scx-cake-crate-packaging closed. Branch renamed to fix/scx-cake-cargo-bump-1-1-3, pushed to rrnewton/scx, PR opened sched-ext/scx#3604 against sched-ext/scx:main. Worktree retained pending review/merge.
hodgesds
approved these changes
May 27, 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.
Summary
Follow-up to #3583 / commits 97cf25f + 11cb5f2 that landed the symlink-based path fix for
scx_cake(the same patternscx_cosmosadopted in commit 605c7d2). That fix resolved the originalblocking
cargo install scx_cakefrom crates.io for 1.1.1. However,scx_cake1.1.2 still cannot install from crates.io for a closely-related but distinct reason — surfaced only bycargo package -p scx_cake(verify step) end-to-end against the published deps:Why
Unlike
scx_cosmos(which only bundlespmu.bpf.c),scx_cakebundlessdt_alloc.bpf.candsdt_task.bpf.c— both of which now use thescx_err_loc/scx_err/scx_out_locmacros introduced in commit 73b4543 (lib: move allocators to BPF streams reporting, 2026-05-13). Those macros live inscheds/include/lib/alloc/bpf_helpers_local.h, which ships inside thescx_cargocrate'sbpf_htarball.But the
scx_cargoon crates.io is still 1.1.1 (published 2026-05-13, before the streams refactor). Its bundledbpf_helpers_local.hpredates the macros, so anycake1.1.2 install from crates.io against the publishedscx_cargo1.1.1 fails clang at sdt_alloc.Fix
Re-publish
scx_cargowith the current (post-streams)bpf_h, and bumpscx_caketo consume it:rust/scx_cargo:1.1.1→1.1.2(no code change —bpf_his a symlink to../../scheds/include, resolved atcargo packagetime, so the bump alone carries the updatedbpf_helpers_local.hto crates.io)scheds/rust/scx_cake:1.1.2→1.1.3, and bump build-depscx_cargo"1.1.1"→"1.1.2"Cargo.lockupdated to matchRelease ordering
scx_cargo1.1.2 must be published to crates.io beforescx_cake1.1.3 so cargo can resolve the new build-dep version.Test plan
Local pre-publish simulation (the published
scx_cargo1.1.2 doesn't exist yet, so the standardcargo package --verifychicken-and-eggs — the workaround mirrors whatcargo installwill do post-publish):cargo build -p scx_cakeclean (workspace path deps)cargo package -p scx_cargo -p scx_cake --no-verifyproduces both tarballsExtract both tarballs side-by-side under
/tmp/cake-install-sim/:scx_cargo-1.1.2/bpf_h/lib/alloc/bpf_helpers_local.hcontainsscx_err_loc✓scx_cake-1.1.3/src/bpf/lib/contains all 8 lib.bpf.cfiles referenced bybuild.rs✓In extracted
scx_cake-1.1.3/, injectthen
cargo build— succeeds end-to-end.scx_err_locresolves via the newbpf_htar thatscx_cargo1.1.2 ships, and alladd_source("src/bpf/lib/*.bpf.c")paths resolve inside the flat extracted tarball. This is the most faithful local simulation ofcargo install scx_cakepost-publish: the contents inside the extracted tarballs are exactly what the registry would serve.Reviewer / release engineer: publish
scx_cargo1.1.2 first, thenscx_cake1.1.3, thencargo install scx_cakefrom a clean toolchain to confirm crates.io install path.