Skip to content

[bazel] Bump up cc and rust toolchains#14542

Merged
zbarsky-openai merged 2 commits intomainfrom
zbarsky/bumps
Mar 13, 2026
Merged

[bazel] Bump up cc and rust toolchains#14542
zbarsky-openai merged 2 commits intomainfrom
zbarsky/bumps

Conversation

@zbarsky-openai
Copy link
Copy Markdown
Contributor

@zbarsky-openai zbarsky-openai commented Mar 13, 2026

This lets us drop various patches and go all the way to a very clean setup.

In case folks are curious what was going on... we were depending on the toolchain finding stdlib headers as sibling files of clang++, and for linking we were providing a -resource-dir containing the runtime libs. However, some users of the cc toolchain (such as rust build scripts) do the equivalent of $CC $CCFLAGS $LDFLAGS so the -resource-dir was being passed when compiling, which suppressed the default stdlib header location logic. The upstream fix was to swap to using -isystem to pass the stdlib headers, while carefully controlling the ordering to simulate them coming from the resource-dir.

inject_repo(crate, "zstd")

bazel_dep(name = "bzip2", version = "1.0.8.bcr.3")
bazel_dep(name = "libcap", version = "2.27.bcr.1")
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

moves this to not be interspersed with the modules used in the crates

Copy link
Copy Markdown
Collaborator

@bolinfest bolinfest left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So pretty!

common:remote --jobs=800
# TODO(team): Evaluate if this actually helps, zbarsky is not sure, everything seems bottlenecked on `core` either way.
# Enable pipelined compilation since we are not bound by local CPU count.
#common:remote --@rules_rust//rust/settings:pipelined_compilation
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, so we're leaving this commented out for now?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, I wasn't sure if this was better or not, so I left a breadcrumb to make it easy to evaluate as a followup

@zbarsky-openai zbarsky-openai merged commit 8567e3a into main Mar 13, 2026
16 checks passed
@zbarsky-openai zbarsky-openai deleted the zbarsky/bumps branch March 13, 2026 18:01
@github-actions github-actions bot locked and limited conversation to collaborators Mar 13, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

2 participants