Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,742 changes: 1,088 additions & 654 deletions BUCK

Large diffs are not rendered by default.

284 changes: 176 additions & 108 deletions Cargo.lock

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ rustc-main = { path = "rust/compiler/rustc", artifact = ["bin"], features = ["ll
rustdoc-tool = { path = "rust/src/tools/rustdoc", artifact = ["bin"] }

[patch.crates-io]
compiler_builtins = { path = "rust/library/compiler-builtins/compiler-builtins" }
rustc-std-workspace-alloc = { path = "rust/library/rustc-std-workspace-alloc" }
rustc-std-workspace-core = { path = "rust/library/rustc-std-workspace-core" }
rustc-std-workspace-std = { path = "rust/library/rustc-std-workspace-std" }
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,16 @@ These do not need to be run in any particular order.
# Download crates.io dependencies
$ buck2 uquery 'kind(crate_download, ...)' | xargs buck2 build

# Check standard library and rustc using bootstrap compiler in #[cfg(bootstrap)]
$ buck2 build stage1:std[check]
# Typecheck stage1 compiler using bootstrap compiler with #[cfg(bootstrap)]
$ buck2 build stage1:rustc[check]

# Build and run stage1 compiler
$ buck2 build stage1:rustc
$ buck2 run stage1:rustc -- --version --verbose

# Typecheck standard library using stage1 compiler
$ buck2 build stage1:std[check]

# Build and run stage2 compiler in #[cfg(not(bootstrap))] using stage1 compiler
$ buck2 build stage2:rustc
$ buck2 run stage2:rustc -- --version --verbose
Expand Down
3 changes: 2 additions & 1 deletion fixups/clippy_lints/fixups.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ extra_deps = [
":rustc_arena-0.0.0",
":rustc_ast-0.0.0",
":rustc_ast_pretty-0.0.0",
":rustc_attr_parsing-0.0.0",
":rustc_attr_data_structures-0.0.0",
":rustc_data_structures-0.0.0",
":rustc_driver-0.0.0",
":rustc_errors-0.0.0",
Expand All @@ -24,5 +24,6 @@ extra_deps = [
":rustc_span-0.0.0",
":rustc_target-0.0.0",
":rustc_trait_selection-0.0.0",
":smallvec-1.15.1",
":thin-vec-0.2.14",
]
2 changes: 2 additions & 0 deletions fixups/clippy_utils/fixups.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
extra_deps = [
":indexmap-2.10.0",
":rustc_abi-0.0.0",
":rustc_ast-0.0.0",
":rustc_attr_data_structures-0.0.0",
":rustc_attr_parsing-0.0.0",
":rustc_const_eval-0.0.0",
":rustc_data_structures-0.0.0",
Expand Down
2 changes: 2 additions & 0 deletions fixups/compiler_builtins/fixups.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
extra_srcs = ["../libm/src/math/**/*.rs"]

rustc_flags = [
# Port of Cargo change: https://github.com/rust-lang/rust/pull/73136/files
#
Expand Down
5 changes: 5 additions & 0 deletions fixups/rustc_proc_macro/fixups.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
extra_srcs = ["../../library/proc_macro/**/*.rs"]

# This is a compiler crate despite having source code located in the library
# directory.
target_compatible_with = ["//constraints:compiler"]
2 changes: 1 addition & 1 deletion fixups/rustdoc/fixups.toml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
buildscript.run = true
cargo_env = ["CARGO_MANIFEST_DIR"]
extra_deps = [
"toolchains//rust:sysroot[test]",
":pulldown-cmark-0.11.3",
":rustc_abi-0.0.0",
":rustc_ast-0.0.0",
":rustc_ast_pretty-0.0.0",
":rustc_attr_data_structures-0.0.0",
":rustc_attr_parsing-0.0.0",
":rustc_data_structures-0.0.0",
":rustc_driver-0.0.0",
Expand Down
8 changes: 4 additions & 4 deletions platforms/BUCK
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ execution_platforms(
name = "execution",
platforms = [
":host",
"//platforms/stage1:library",
"//platforms/stage1:library-build-script",
"//platforms/stage1:compiler",
"//platforms/stage1:compiler-build-script",
"//platforms/stage2:library",
"//platforms/stage2:library-build-script",
"//platforms/stage1:library",
"//platforms/stage1:library-build-script",
"//platforms/stage2:compiler",
"//platforms/stage2:compiler-build-script",
"//platforms/stage2:library",
"//platforms/stage2:library-build-script",
],
)
2 changes: 1 addition & 1 deletion rust
Submodule rust updated 6789 files
14 changes: 7 additions & 7 deletions stage0/BUCK
Original file line number Diff line number Diff line change
Expand Up @@ -69,17 +69,17 @@ stage0_sysroot(

ci_artifact(
name = "rust_dev",
commit = "645b44edd3717f02838d07ba9bdd2554b0cdc0c5",
commit = "b1237106c5e2d06b3874865bef6fc79181de32bf",
component = "rust-dev-beta",
incoming_transition = ":stage0_configuration",
manifest = "//:stage0_manifest",
sha256 = {
"aarch64-apple-darwin": "3f9dcd8e37f75c3cb55a727f3c9fbc09fa27475fedf281718b660250f7c42608",
"aarch64-pc-windows-msvc": "11826276146a153d512c8852cef3638697cff365b0e4eb79b8854e792322b7e0",
"aarch64-unknown-linux-gnu": "9e8b53d48279319d418b3cd9ff343ba69645b5a2a2aff2309a40b6c6b2a71337",
"x86_64-apple-darwin": "0f451ce6ff5868bf09102d9c5be567632c20e2ffd4c6f282b6410fb8c6cd41cd",
"x86_64-pc-windows-msvc": "d957af07a2406f760b6f2437cf01266872497d5d697fa3004d650ee8bc2da580",
"x86_64-unknown-linux-gnu": "818b47df157c4d0cca3a32fab72092048e2f29b095dfcf316cd3c790fcad53d4",
"aarch64-apple-darwin": "00b60db97f509682e521687b2118361de2bfed175758b8c2a5319e9e521aab93",
"aarch64-pc-windows-msvc": "7ca8d82470afe815c6c27dd4ccf93319d83fd3531f1040661576dae68e314ec6",
"aarch64-unknown-linux-gnu": "7fc2a25a67c30d0566f39421e16a0e0f9a3928b083f36a96b9bd344819f21ae9",
"x86_64-apple-darwin": "610e8aa0c721b42ab5526e1918dc99c08615ea425dcab9687d00b130005c905a",
"x86_64-pc-windows-msvc": "4d4b5d47a4a8c25802dece8d4eee1682144da7d81b9164a55f75312ea45b90c0",
"x86_64-unknown-linux-gnu": "5a2c511322715777f68b7e43e52c40b98f1b94338f0e78fd7901aaa15f8f19a3",
},
)

Expand Down
63 changes: 35 additions & 28 deletions toolchains/BUCK
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,15 @@ rust_toolchain(
"rust//constraints:stage2": "rust//stage1:clippy-driver",
}),
compiler = select({
"rust//constraints:stage1": "rust//stage0:rustc",
"rust//constraints:stage2": select({
"rust//constraints:library": "rust//stage1:rustc",
"rust//constraints:stage1": select({
"rust//constraints:compiler": "rust//stage0:rustc",
"rust//constraints:library-build-script": "rust//stage0:rustc",
"rust//constraints:library": "rust//stage1:rustc",
}),
"rust//constraints:stage2": select({
"rust//constraints:compiler": "rust//stage1:rustc",
"rust//constraints:library-build-script": "rust//stage1:rustc",
"rust//constraints:library": "rust//stage2:rustc",
}),
}),
exec_compatible_with = [
Expand All @@ -60,7 +64,10 @@ rust_toolchain(
"rust//constraints:opt-level=3": "-Copt-level=3",
}),
] + select({
"rust//constraints:stage1": ["--cfg=bootstrap"],
"rust//constraints:stage1": select({
"rust//constraints:compiler": ["--cfg=bootstrap"],
"rust//constraints:library": [],
}),
"rust//constraints:stage2": [],
}) + select({
"DEFAULT": [],
Expand All @@ -72,32 +79,32 @@ rust_toolchain(
}),
sysroot = select({
"rust//constraints:library": None,
"rust//constraints:library-build-script": "rust//stage0:sysroot",
"rust//constraints:library-build-script": select({
"rust//constraints:stage1": "rust//stage0:sysroot",
"rust//constraints:stage2": dict(
alloc = "rust//stage1:alloc",
compiler_builtins = "rust//stage1:compiler_builtins",
core = "rust//stage1:core",
panic_abort = "rust//stage1:panic_abort",
panic_unwind = "rust//stage1:panic_unwind",
proc_macro = "rust//stage1:proc_macro",
rust_allocator = "rust//stage1:rust_allocator",
std = "rust//stage1:std",
test = "rust//stage1:test",
),
}),
"rust//constraints:compiler": select({
"rust//constraints:stage1": select({
"rust//constraints:build-script=true": "rust//stage0:sysroot",
"rust//constraints:build-script=false": dict(
alloc = "rust//stage1:alloc",
compiler_builtins = "rust//stage1:compiler_builtins",
core = "rust//stage1:core",
panic_abort = "rust//stage1:panic_abort",
panic_unwind = "rust//stage1:panic_unwind",
proc_macro = "rust//stage1:proc_macro",
rust_allocator = "rust//stage1:rust_allocator",
std = "rust//stage1:std",
test = "rust//stage1:test",
),
}),
"rust//constraints:stage1": "rust//stage0:sysroot",
"rust//constraints:stage2": dict(
alloc = "rust//stage2:alloc",
compiler_builtins = "rust//stage2:compiler_builtins",
core = "rust//stage2:core",
panic_abort = "rust//stage2:panic_abort",
panic_unwind = "rust//stage2:panic_unwind",
proc_macro = "rust//stage2:proc_macro",
rust_allocator = "rust//stage2:rust_allocator",
std = "rust//stage2:std",
test = "rust//stage2:test",
alloc = "rust//stage1:alloc",
compiler_builtins = "rust//stage1:compiler_builtins",
core = "rust//stage1:core",
panic_abort = "rust//stage1:panic_abort",
panic_unwind = "rust//stage1:panic_unwind",
proc_macro = "rust//stage1:proc_macro",
rust_allocator = "rust//stage1:rust_allocator",
std = "rust//stage1:std",
test = "rust//stage1:test",
),
}),
}),
Expand Down
Loading