Skip to content

Remove compiler-builtins from rustc-dep-of-std dependencies #77

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tgross35
Copy link

@tgross35 tgross35 commented Jun 5, 2025

Since 1, this will come automatically from rustc-std-workspace-core and the crates.io dependency should no longer be specified.

Since [1], this will come automatically from `rustc-std-workspace-core`
and the crates.io dependency should no longer be specified.

[1]: rust-lang/rust#141993
@tgross35
Copy link
Author

tgross35 commented Jun 5, 2025

@Manishearth once rust-lang/rust#141993 lands, would it be possible to merge this PR and do a patch release reasonably quick? Once that lands there will be a bit of a race between crates that depend on compiler_builtins from crates.io and tools that need to patch it to the local version, so the shorter that time is the better.

@Manishearth
Copy link
Member

Sure

rust-bors bot added a commit to rust-lang/rust that referenced this pull request Jun 5, 2025
Use the in-tree `compiler-builtins` for the sysroot

Many of `std`'s dependency have a dependency on the crates.io `compiler-builtins` when used with the feature `rustc-std-workspace-core`. Use a Cargo patch to select the in-tree version instead.

`compiler-builtins` is also added as a dependency of `rustc-std-workspace-core` so these crates can remove their crates.io dependency in the future.

Zulip discussion: [#t-compiler > Using in-tree compiler-builtins](https://rust-lang.zulipchat.com/#narrow/channel/131828-t-compiler/topic/Using.20in-tree.20compiler-builtins/with/522445336)

Once this merges, the following PRs will need to make it to a release for the relevant crates:

- rust-lang/getopts#119 (can merge at any time)
- rust-lang/hashbrown#625 (can merge at any time)
- rust-lang/stdarch#1825
- rust-lang/rustc-demangle#80
- rust-lang/cfg-if#84
- unicode-rs/unicode-width#77

The above should cover all tier 1 targets. The remaining cover the rest:

- `dlmalloc` (wasm, xous, sgx) alexcrichton/dlmalloc-rs#50
- `gimli` (xous)
- `r-efi`, `r-efi-alloc` (efi)
- `fortanix-sgx-abi` (sgx)
- `hermit-abi` (hermit)
- `wasi` (wasi)

try-job: dist-x86_64-linux
try-job: x86_64-gnu
try-job: x86_64-gnu-aux
try-job: test-various
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