Skip to content
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

bootstrap is broken for all custom targets on rust-1.85.0_beta #137064

Open
stefson opened this issue Feb 15, 2025 · 13 comments
Open

bootstrap is broken for all custom targets on rust-1.85.0_beta #137064

stefson opened this issue Feb 15, 2025 · 13 comments
Labels
C-bug Category: This is a bug. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

Comments

@stefson
Copy link

stefson commented Feb 15, 2025

hello everyone,

I've been using a custom target for my locally built rustc toolchain for many years now, the target is added with a custom patch and everything has been working just fine:

rustc 1.84.0 (9fc6b4312 2025-01-07) (built from a source tarball)
binary: rustc
commit-hash: 9fc6b43126469e3858e2fe86cafb4f0fd5068869
commit-date: 2025-01-07
host: armv7a-unknown-linux-musleabihf
release: 1.84.0
LLVM version: 19.1.5
rustc --print target-list | grep armv7a-unknown
> armv7a-unknown-linux-musleabihf

with the branching of the 1.85.0_beta branch, the already built-in target of the local rustc-1.84.0 binary cannot be found anymore by the bootstrap process:

running: /var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/build/bootstrap/debug/bootstrap build -vv --config=/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/config.toml -j1
WARNING: The `change-id` is missing in the `config.toml`. This means that you will not be able to track the major changes made to the bootstrap configurations.
NOTE: to silence this warning, add `change-id = 134650` at the top of `config.toml`
finding compilers


error occurred: unknown target `armv7a-unknown-linux-musleabihf`


Traceback (most recent call last):
  File "/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/./x.py", line 53, in <module>
    bootstrap.main()
  File "/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/src/bootstrap/bootstrap.py", line 1333, in main
    bootstrap(args)
  File "/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/src/bootstrap/bootstrap.py", line 1308, in bootstrap
    run(args, env=env, verbose=build.verbose, is_bootstrap=True)
  File "/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/src/bootstrap/bootstrap.py", line 236, in run
    raise RuntimeError(err)
RuntimeError: failed to run: /var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/build/bootstrap/debug/bootstrap build -vv --config=/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/config.toml -j1

the full build.log: build.log.gz

this is my config.toml:

[llvm]
download-ci-llvm = false
optimize = true
release-debuginfo = false
assertions = false
ninja = true
targets = "ARM"
experimental-targets = ""
link-shared = false
[build]
build = "armv7a-unknown-linux-musleabihf"
host = ["armv7a-unknown-linux-musleabihf"]
target = ["armv7a-unknown-linux-musleabihf"]
cargo = "/usr/lib/rust/1.84.0/bin/cargo"
rustc = "/usr/lib/rust/1.84.0/bin/rustc"
docs = false
compiler-docs = false
submodules = false
python = "python3.12"
locked-deps = true
vendor = true
extended = true
tools = ["cargo","rustdoc"]
verbose = 2
sanitizers = false
cargo-native-static = false
[install]
prefix = "/usr/lib/rust/1.85.0_beta"
sysconfdir = "etc"
docdir = "share/doc/rust"
bindir = "bin"
libdir = "lib"
mandir = "share/man"
[rust]
# https://github.com/rust-lang/rust/issues/54872
codegen-units-std = 1
optimize = true
debug = false
debug-assertions = false
debuginfo-level-rustc = 0
backtrace = true
incremental = false
default-linker = "armv7a-unknown-linux-musleabihf-gcc"
channel = "stable"
rpath = false
verbose-tests = true
optimize-tests = true
codegen-tests = true
dist-src = false
# https://github.com/rust-lang/rust/issues/117885
remap-debuginfo = true
lld = false
backtrace-on-ice = true
jemalloc = false
# See https://github.com/rust-lang/rust/issues/121124
lto = "off"
[dist]
src-tarball = false
compression-formats = ["xz"]
[target.armv7a-unknown-linux-musleabihf]
cc = "armv7a-unknown-linux-musleabihf-gcc"
cxx = "armv7a-unknown-linux-musleabihf-g++"
linker = "armv7a-unknown-linux-musleabihf-gcc"
ar = "armv7a-unknown-linux-musleabihf-ar"
crt-static = false

operating system is gentoo, both armv7a and amd64

here are the backtraces:

RUST_BACKTRACE=1 /var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/build/bootstrap/debug/bootstrap build -vv --config=/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/config.toml -j1
thread 'main' panicked at src/bootstrap/src/bin/main.rs:38:43:
fs::OpenOptions::new().write(true).truncate(true).create(true).open(&lock_path) failed with No such file or directory (os error 2)
stack backtrace:
   0: rust_begin_unwind
   1: core::panicking::panic_fmt
   2: bootstrap::main
             at ./work/rustc-beta-src/src/bootstrap/src/bin/main.rs:38:43
   3: core::ops::function::FnOnce::call_once
             at /rustc/9fc6b43126469e3858e2fe86cafb4f0fd5068869/library/core/src/ops/function.rs:250:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
 RUST_BACKTRACE=full /var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/build/bootstrap/debug/bootstrap build -vv --config=/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/config.toml -j1
thread 'main' panicked at src/bootstrap/src/bin/main.rs:38:43:
fs::OpenOptions::new().write(true).truncate(true).create(true).open(&lock_path) failed with No such file or directory (os error 2)
stack backtrace:
   0:   0xf306d0 - <std::sys::backtrace::BacktraceLock::print::DisplayBacktrace as core::fmt::Display>::fmt::hc18560b2598d9e23
   1:   0xf5e460 - core::fmt::write::h1d71005846ea8a6f
   2:   0xf2b7f0 - std::io::Write::write_fmt::h0ee65933c12a137e
   3:   0xf30564 - std::sys::backtrace::BacktraceLock::print::h12961e334efd2170
   4:   0xf31ee4 - std::panicking::default_hook::{{closure}}::h5a0b1665890f1cc2
   5:   0xf31cdc - std::panicking::default_hook::h314f25ba09977fe2
   6:   0xf32634 - std::panicking::rust_panic_with_hook::hbfa151c65a0e5210
   7:   0xf32324 - std::panicking::begin_panic_handler::{{closure}}::h97bdd921809c6f05
   8:   0xf30c40 - std::sys::backtrace::__rust_end_short_backtrace::hf1a1e2e30f5a34d8
   9:   0xf3204c - rust_begin_unwind
  10:   0x45d1a4 - core::panicking::panic_fmt::hf8aa1f743ac38530
  11:   0x462e80 - bootstrap::main::h7df149a85fdac2da
                       at /var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/src/bootstrap/src/bin/main.rs:38:43
  12:   0x462084 - core::ops::function::FnOnce::call_once::he4f8c341d28a4588
                       at /rustc/9fc6b43126469e3858e2fe86cafb4f0fd5068869/library/core/src/ops/function.rs:250:5
  13:   0x466904 - std::sys::backtrace::__rust_begin_short_backtrace::h8b2447e5dd3de0c0
                       at /rustc/9fc6b43126469e3858e2fe86cafb4f0fd5068869/library/std/src/sys/backtrace.rs:154:18
  14:   0x461e18 - std::rt::lang_start::{{closure}}::hfef738705190f40a
                       at /rustc/9fc6b43126469e3858e2fe86cafb4f0fd5068869/library/std/src/rt.rs:195:18
  15:   0xf2137c - std::rt::lang_start_internal::h5a47ea8ee334112b
  16:   0x461df0 - std::rt::lang_start::h501fb101ec03ed78
                       at /rustc/9fc6b43126469e3858e2fe86cafb4f0fd5068869/library/std/src/rt.rs:194:17
  17:   0x464670 - main
@stefson stefson added C-bug Category: This is a bug. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) labels Feb 15, 2025
@rustbot rustbot added the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Feb 15, 2025
@onur-ozkan
Copy link
Member

Can you check if setting BOOTSTRAP_SKIP_TARGET_SANITY=1 make it work?

@onur-ozkan onur-ozkan removed the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Feb 15, 2025
@stefson
Copy link
Author

stefson commented Feb 15, 2025

like this?

 BOOTSTRAP_SKIP_TARGET_SANITY=1 /var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/build/bootstrap/debug/bootstrap build -vv --config=/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/config.toml -j1

@onur-ozkan
Copy link
Member

You should use bootstrap scripts (x or x.py) instead of bare bootstrap binary.

@stefson
Copy link
Author

stefson commented Feb 15, 2025

ok, so here is the result of

BOOTSTRAP_SKIP_TARGET_SANITY=1 RUST_BACKTRACE=full RUSTC_BOOTSTRAP=1 python3.12 ./x.py build -vv --config=./config.toml -j1

    Finished `dev` profile [unoptimized] target(s) in 13m 04s
running: /var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/build/bootstrap/debug/bootstrap build -vv --config=/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/config.toml -j1
WARNING: The `change-id` is missing in the `config.toml`. This means that you will not be able to track the major changes made to the bootstrap configurations.
NOTE: to silence this warning, add `change-id = 134650` at the top of `config.toml`
finding compilers


error occurred: unknown target `armv7a-unknown-linux-musleabihf`


Traceback (most recent call last):
  File "/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/./x.py", line 53, in <module>
    bootstrap.main()
  File "/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/src/bootstrap/bootstrap.py", line 1338, in main
    bootstrap(args)
  File "/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/src/bootstrap/bootstrap.py", line 1313, in bootstrap
    run(args, env=env, verbose=build.verbose, is_bootstrap=True)
  File "/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/src/bootstrap/bootstrap.py", line 236, in run
    raise RuntimeError(err)
RuntimeError: failed to run: /var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/build/bootstrap/debug/bootstrap build -vv --config=/var/tmp/portage/dev-lang/rust-1.85.0_beta/work/rustc-beta-src/config.toml -j1

so that doesn't make any difference, I'm afraid.

@arachsys
Copy link

arachsys commented Feb 20, 2025

I'm seeing this too on the now released rust-1.85.0, with (longstanding) {aarch64,x86_64}-$VENDOR-linux-musl targets added in compiler/rustc_target/src/spec/targets/ and in the table in compiler/rustc_target/src/spec/mod.rs. The custom target worked fine up to and including rust-1.84.1, but aborts on bootstrap with rust-1.85.0.

(To preempt worries that targets/*-$VENDOR-linux-musl.rs are invalid, I can reproduce when they are literally a copy of the corresponding *-unknown-linux-musl.rs. Nowadays my vendor target's only difference is to remove the incorrect static-link default on my native musl system, so there's nothing tricky going on.)

A bit of println!() debugging suggests we fail on

let compiler = cfg.get_compiler();

of find_target() in src/bootstrap/src/utils/cc_detect.rs.

Explicitly specifying cc = "/bin/cc" etc. in the target section of config.toml doesn't change this behaviour, and strace suggests bootstrap execs rustc --version --verbose to get the target name, but never tries to run cc, c++, ar, etc.

@arachsys
Copy link

arachsys commented Feb 21, 2025

This seems to be related to the cc-rs mistake discussed in rust-lang/cc-rs#1317 - this introduced a hard-coded list of targets (!!) which broke custom rust packaging on Alpine Linux, Chimera Linux and others, though it hadn't made it all the way out to break a 'stable' rust release at the point they all reported it.

The bootstrap build works fine if you bodge the hard-coded list in the vendored cc crate:

diff --git a/vendor/cc-1.2.0/src/target/generated.rs b/vendor/cc-1.2.0/src/target/generated.rs
index 0c9b0ae1..23d18039 100644
--- a/vendor/cc-1.2.0/src/target/generated.rs
+++ b/vendor/cc-1.2.0/src/target/generated.rs
@@ -124,6 +124,18 @@ pub(crate) const LIST: &[(&str, TargetInfo<'static>)] = &[
             unversioned_llvm_target: "arm64-apple-watchos-simulator",
         },
     ),
+    (
+        "aarch64-arachsys-linux-musl",
+        TargetInfo {
+            full_arch: "aarch64",
+            arch: "aarch64",
+            vendor: "arachsys",
+            os: "linux",
+            env: "musl",
+            abi: "",
+            unversioned_llvm_target: "aarch64-arachsys-linux-musl",
+        },
+    ),
     (
         "aarch64-fuchsia",
         TargetInfo {
@@ -2848,6 +2860,18 @@ pub(crate) const LIST: &[(&str, TargetInfo<'static>)] = &[
             unversioned_llvm_target: "x86_64-apple-watchos-simulator",
         },
     ),
+    (
+        "x86_64-arachsys-linux-musl",
+        TargetInfo {
+            full_arch: "x86_64",
+            arch: "x86_64",
+            vendor: "arachsys",
+            os: "linux",
+            env: "musl",
+            abi: "",
+            unversioned_llvm_target: "x86_64-arachsys-linux-musl",
+        },
+    ),
     (
         "x86_64-fortanix-unknown-sgx",
         TargetInfo {

@stefson
Copy link
Author

stefson commented Feb 21, 2025

I tried to copy your approach:

diff --git a/vendor/cc-1.2.0/src/target/generated.rs b/vendor/cc-1.2.0/src/target/generated.rs
index 0c9b0ae..ee14246 100644
--- a/vendor/cc-1.2.0/src/target/generated.rs
+++ b/vendor/cc-1.2.0/src/target/generated.rs
@@ -832,6 +832,18 @@ pub(crate) const LIST: &[(&str, TargetInfo<'static>)] = &[
             unversioned_llvm_target: "armv7-unknown-linux-gnueabi",
         },
     ),
+    (
+        "armv7a-unknown-linux-musleabihf",
+        TargetInfo {
+            full_arch: "armv7a",
+            arch: "arm",
+            vendor: "unknown",
+            os: "linux",
+            env: "musl",
+            abi: "eabihf",
+            unversioned_llvm_target: "armv7-unknown-linux-gnueabihf",
+        },
+    ),
     (
         "armv7-unknown-linux-musleabihf",
         TargetInfo {

sadly it didn't work for me, and failed with the same error as before.

@arachsys
Copy link

arachsys commented Feb 21, 2025

Ah, sorry to hear that - possibly something about the way I build rust allows this to work for me and not for you? My build recipe is at https://github.com/arachsys/packages/tree/master/rust and you can see the diff I needed to get the 1.85.0 release tarball building (with both 1.84.1 and itself) at arachsys/packages@7596f3fac1. (The only relevant bit of that diff for you is probably the change to target.diff, and I can't see anything that might make me too 'unusual' in the build script itself.)

One thing I didn't think of last night: you'll definitely have to work around the ridiculous file checksums if you patch vendor/cc-* in the source tree with upstream cargo. You can just remove the entire "files" key from them with sed:

sed -i -E 'H;1h;$!d;x;s/("files"\s*:\s*\{)("([^"\\]|\\.)*"|[^"}])*/\1/' vendor/*/.cargo-checksum.json

or disable this (deliberately user-hostile) behaviour altogether with something like arachsys/packages@bdc6635b5e.

@onur-ozkan onur-ozkan marked this as a duplicate of #137368 Feb 21, 2025
@heitbaum
Copy link

How are we progressing with a fix for this build issue?

@onur-ozkan
Copy link
Member

onur-ozkan commented Feb 22, 2025

Can you downgrade bootstrap cc to =1.1.22 and check if it works? I hope other versions of cc from compiler and library tree will not effect this.

@bcressey
Copy link
Contributor

@stefson the generated list is searched via binary search:

generated::LIST.binary_search_by_key(&target_triple, |(target_triple, _)| target_triple)

So any new entries you add need to be in sorted order - your armv7a-unknown-linux-musleabihf target should not come before armv7-unknown-linux-musleabihf.

I did the same thing when adding my *-bottlerocket-linux-* targets and it took me a while to track down.

(Thanks @arachsys for the patch!)

@heitbaum
Copy link

Can you downgrade bootstrap cc to =1.1.22 and check if it works? I hope other versions of cc from compiler and library tree will not effect this.

I can confirm that this patch does allow the build of bootstrap to complete.

diff -Nu rustc-1.85.0-src/src/bootstrap/Cargo.toml rust-1.85.0/src/bootstrap/Cargo.toml
--- rustc-1.85.0-src/src/bootstrap/Cargo.toml   2025-02-17 18:17:27.000000000 +0000
+++ rust-1.85.0/src/bootstrap/Cargo.toml        2025-02-22 22:29:29.083321273 +0000
@@ -36,7 +36,7 @@
 # Most of the time updating these dependencies requires modifications to the
 # bootstrap codebase(e.g., https://github.com/rust-lang/rust/issues/124565);
 # otherwise, some targets will fail. That's why these dependencies are explicitly pinned.
-cc = "=1.2.0"
+cc = "=1.1.22"
 cmake = "=0.1.48"
 
 build_helper = { path = "../build_helper" }
diff -Nu rustc-1.85.0-src/src/bootstrap/bootstrap.py rust-1.85.0/src/bootstrap/bootstrap.py
--- rustc-1.85.0-src/src/bootstrap/bootstrap.py 2025-02-17 18:17:27.000000000 +0000
+++ rust-1.85.0/src/bootstrap/bootstrap.py      2025-02-22 22:31:44.312261598 +0000
@@ -1131,8 +1131,6 @@
         args.extend("--verbose" for _ in range(self.verbose))
         if self.use_locked_deps:
             args.append("--locked")
-        if self.use_vendored_sources:
-            args.append("--frozen")
         if self.get_toml("metrics", "build"):
             args.append("--features")
             args.append("build-metrics")
diff -Nu rustc-1.85.0-src/src/bootstrap/Cargo.lock rust-1.85.0/src/bootstrap/Cargo.lock
--- rustc-1.85.0-src/src/bootstrap/Cargo.lock   2025-02-17 18:17:27.000000000 +0000
+++ rust-1.85.0/src/bootstrap/Cargo.lock        2025-02-22 22:31:50.301318838 +0000
@@ -65,9 +65,9 @@
 
 [[package]]
 name = "bstr"
-version = "1.10.0"
+version = "1.11.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "40723b8fb387abc38f4f4a37c09073622e41dd12327033091ef8950659e6dc0c"
+checksum = "786a307d683a5bf92e6fd5fd69a7eb613751668d1d8d67d802846dfe367c62c8"
 dependencies = [
  "memchr",
  "regex-automata",
@@ -84,9 +84,9 @@
 
 [[package]]
 name = "cc"
-version = "1.2.0"
+version = "1.1.22"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1aeb932158bd710538c73702db6945cb68a8fb08c519e6e12706b94263b36db8"
+checksum = "9540e661f81799159abee814118cc139a2004b3a3aa3ea37724a1b66530b90e0"
 dependencies = [
  "shlex",
 ]
@@ -99,9 +99,9 @@
 
 [[package]]
 name = "clap"
-version = "4.5.20"
+version = "4.5.23"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b97f376d85a664d5837dbae44bf546e6477a679ff6610010f17276f686d867e8"
+checksum = "3135e7ec2ef7b10c6ed8950f0f792ed96ee093fa088608f1c76e569722700c84"
 dependencies = [
  "clap_builder",
  "clap_derive",
@@ -109,9 +109,9 @@
 
 [[package]]
 name = "clap_builder"
-version = "4.5.20"
+version = "4.5.23"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "19bc80abd44e4bed93ca373a0704ccbd1b710dc5749406201bb018272808dc54"
+checksum = "30582fc632330df2bd26877bde0c1f4470d57c582bbc070376afcd04d8cb4838"
 dependencies = [
  "anstyle",
  "clap_lex",
@@ -119,9 +119,9 @@
 
 [[package]]
 name = "clap_complete"
-version = "4.5.37"
+version = "4.5.40"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "11611dca53440593f38e6b25ec629de50b14cdfa63adc0fb856115a2c6d97595"
+checksum = "ac2e663e3e3bed2d32d065a8404024dad306e699a04263ec59919529f803aee9"
 dependencies = [
  "clap",
 ]
@@ -140,9 +140,9 @@
 
 [[package]]
 name = "clap_lex"
-version = "0.7.2"
+version = "0.7.4"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97"
+checksum = "f46ad14479a25103f283c0f10005961cf086d8dc42205bb44c46ac563475dca6"
 
 [[package]]
 name = "cmake"
@@ -161,18 +161,18 @@
 
 [[package]]
 name = "cpufeatures"
-version = "0.2.15"
+version = "0.2.16"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "0ca741a962e1b0bff6d724a1a0958b686406e853bb14061f218562e1896f95e6"
+checksum = "16b80225097f2e5ae4e7179dd2266824648f3e2f49d9134d584b76389d31c4c3"
 dependencies = [
  "libc",
 ]
 
 [[package]]
 name = "crossbeam-deque"
-version = "0.8.5"
+version = "0.8.6"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d"
+checksum = "9dd111b7b7f7d55b72c0a6ae361660ee5853c9af73f70c3c2ef6858b950e2e51"
 dependencies = [
  "crossbeam-epoch",
  "crossbeam-utils",
@@ -189,9 +189,9 @@
 
 [[package]]
 name = "crossbeam-utils"
-version = "0.8.20"
+version = "0.8.21"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80"
+checksum = "d0a5c400df2834b80a4c3327b3aad3a4c4cd4de0629063962b03235697506a28"
 
 [[package]]
 name = "crypto-common"
@@ -221,12 +221,12 @@
 
 [[package]]
 name = "errno"
-version = "0.3.9"
+version = "0.3.10"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba"
+checksum = "33d852cb9b869c2a9b3df2f71a3074817f01e1844f839a144f5fcef059a4eb5d"
 dependencies = [
  "libc",
- "windows-sys 0.52.0",
+ "windows-sys 0.59.0",
 ]
 
 [[package]]
@@ -283,11 +283,11 @@
 
 [[package]]
 name = "home"
-version = "0.5.9"
+version = "0.5.11"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e3d1354bf6b7235cb4a0576c2619fd4ed18183f689b12b006a0ee7329eeff9a5"
+checksum = "589533453244b0995c858700322199b2becb13b627df2851f64a2775d024abcf"
 dependencies = [
- "windows-sys 0.52.0",
+ "windows-sys 0.59.0",
 ]
 
 [[package]]
@@ -308,9 +308,9 @@
 
 [[package]]
 name = "itoa"
-version = "1.0.11"
+version = "1.0.14"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b"
+checksum = "d75a2a4b1b190afb6f5425f10f6a8f959d2ea0b9c2b1d79553551850539e4674"
 
 [[package]]
 name = "junction"
@@ -324,9 +324,9 @@
 
 [[package]]
 name = "libc"
-version = "0.2.167"
+version = "0.2.169"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "09d6582e104315a817dff97f75133544b2e094ee22447d2acf4a74e189ba06fc"
+checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a"
 
 [[package]]
 name = "libredox"
@@ -379,9 +379,9 @@
 
 [[package]]
 name = "object"
-version = "0.36.5"
+version = "0.36.7"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "aedf0a2d09c573ed1d8d85b30c119153926a2b36dce0ab28322c09a117a4683e"
+checksum = "62948e14d923ea95ea2c7c86c71013138b66525b86bdc08d2dcc262bdb497b87"
 dependencies = [
  "memchr",
 ]
@@ -414,27 +414,27 @@
 
 [[package]]
 name = "proc-macro2"
-version = "1.0.89"
+version = "1.0.92"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f139b0662de085916d1fb67d2b4169d1addddda1919e696f3252b740b629986e"
+checksum = "37d3544b3f2748c54e147655edb5025752e2303145b5aefb3c3ea2c78b973bb0"
 dependencies = [
  "unicode-ident",
 ]
 
 [[package]]
 name = "quote"
-version = "1.0.37"
+version = "1.0.38"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b5b9d34b8991d19d98081b46eacdd8eb58c6f2b201139f7c5f643cc155a633af"
+checksum = "0e4dccaaaf89514f546c693ddc140f729f958c247918a13380cccc6078391acc"
 dependencies = [
  "proc-macro2",
 ]
 
 [[package]]
 name = "redox_syscall"
-version = "0.5.7"
+version = "0.5.8"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9b6dfecf2c74bce2466cabf93f6664d6998a69eb21e39f4207930065b27b771f"
+checksum = "03a862b389f93e68874fbf580b9de08dd02facb9a788ebadaf4a3fd33cf58834"
 dependencies = [
  "bitflags",
 ]
@@ -458,15 +458,15 @@
 
 [[package]]
 name = "rustix"
-version = "0.38.40"
+version = "0.38.42"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "99e4ea3e1cdc4b559b8e5650f9c8e5998e3e5c1343b4eaf034565f32318d63c0"
+checksum = "f93dc38ecbab2eb790ff964bb77fa94faf256fd3e73285fd7ba0903b76bedb85"
 dependencies = [
  "bitflags",
  "errno",
  "libc",
  "linux-raw-sys",
- "windows-sys 0.52.0",
+ "windows-sys 0.59.0",
 ]
 
 [[package]]
@@ -492,24 +492,24 @@
 
 [[package]]
 name = "semver"
-version = "1.0.23"
+version = "1.0.24"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b"
+checksum = "3cb6eb87a131f756572d7fb904f6e7b68633f09cca868c5df1c4b8d1a694bbba"
 
 [[package]]
 name = "serde"
-version = "1.0.215"
+version = "1.0.217"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6513c1ad0b11a9376da888e3e0baa0077f1aed55c17f50e7b2397136129fb88f"
+checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70"
 dependencies = [
  "serde_derive",
 ]
 
 [[package]]
 name = "serde_derive"
-version = "1.0.215"
+version = "1.0.217"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ad1e866f866923f252f05c889987993144fb74e722403468a4ebd70c3cd756c0"
+checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0"
 dependencies = [
  "proc-macro2",
  "quote",
@@ -518,9 +518,9 @@
 
 [[package]]
 name = "serde_json"
-version = "1.0.132"
+version = "1.0.134"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d726bfaff4b320266d395898905d0eba0345aae23b54aee3a737e260fd46db03"
+checksum = "d00f4175c42ee48b15416f6193a959ba3a0d67fc699a0db9ad12df9f83991c7d"
 dependencies = [
  "itoa",
  "memchr",
@@ -547,9 +547,9 @@
 
 [[package]]
 name = "syn"
-version = "2.0.87"
+version = "2.0.93"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "25aa4ce346d03a6dcd68dd8b4010bcb74e54e62c90c573f394c46eae99aba32d"
+checksum = "9c786062daee0d6db1132800e623df74274a0a87322d8e183338e01b3d98d058"
 dependencies = [
  "proc-macro2",
  "quote",
@@ -606,9 +606,9 @@
 
 [[package]]
 name = "unicode-ident"
-version = "1.0.13"
+version = "1.0.14"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e91b56cd4cadaeb79bbf1a5645f6b4f8dc5bde8834ad5894a8db35fda9efa1fe"
+checksum = "adb9e6ca4f869e1180728b7950e35922a7fc6397f7b641499e8f3ef06e50dc83"
 
 [[package]]
 name = "version_check"

@heitbaum
Copy link

Simplified

diff -Nu rustc-1.85.0-src/src/bootstrap/Cargo.toml rust-1.85.0/src/bootstrap/Cargo.toml
--- rustc-1.85.0-src/src/bootstrap/Cargo.toml   2025-02-17 18:17:27.000000000 +0000
+++ rust-1.85.0/src/bootstrap/Cargo.toml        2025-02-22 22:29:29.083321273 +0000
@@ -36,7 +36,7 @@
 # Most of the time updating these dependencies requires modifications to the
 # bootstrap codebase(e.g., https://github.com/rust-lang/rust/issues/124565);
 # otherwise, some targets will fail. That's why these dependencies are explicitly pinned.
-cc = "=1.2.0"
+cc = "=1.1.22"
 cmake = "=0.1.48"
 
 build_helper = { path = "../build_helper" }
diff -Nu rustc-1.85.0-src/src/bootstrap/Cargo.lock rust-1.85.0/src/bootstrap/Cargo.lock
--- rustc-1.85.0-src/src/bootstrap/Cargo.lock   2025-02-17 18:17:27.000000000 +0000
+++ rust-1.85.0/src/bootstrap/Cargo.lock        2025-02-22 22:31:50.301318838 +0000
@@ -84,9 +84,9 @@
 
 [[package]]
 name = "cc"
-version = "1.2.0"
+version = "1.1.22"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1aeb932158bd710538c73702db6945cb68a8fb08c519e6e12706b94263b36db8"
+checksum = "9540e661f81799159abee814118cc139a2004b3a3aa3ea37724a1b66530b90e0"
 dependencies = [
  "shlex",
 ]

fmease added a commit to fmease/rust that referenced this issue Feb 25, 2025
downgrade bootstrap `cc`

Current `cc` version causing bootstrap to fail on custom targets. See rust-lang/cc-rs#1317 for more context.

Fixes (after beta and stable backports): rust-lang#137064 and rust-lang#135271
fmease added a commit to fmease/rust that referenced this issue Feb 25, 2025
downgrade bootstrap `cc`

Current `cc` version causing bootstrap to fail on custom targets. See rust-lang/cc-rs#1317 for more context.

Fixes (after beta and stable backports): rust-lang#137064 and rust-lang#135271
rust-timer added a commit to rust-lang-ci/rust that referenced this issue Feb 25, 2025
Rollup merge of rust-lang#137460 - onur-ozkan:downgrade-cc, r=jieyouxu

downgrade bootstrap `cc`

Current `cc` version causing bootstrap to fail on custom targets. See rust-lang/cc-rs#1317 for more context.

Fixes (after beta and stable backports): rust-lang#137064 and rust-lang#135271
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: This is a bug. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
None yet
Development

No branches or pull requests

6 participants