Skip to content

Build bootstrap with an explicit target#155771

Open
chenyukang wants to merge 1 commit intorust-lang:mainfrom
chenyukang:yukang-fix-155651-bootstrap-build-target
Open

Build bootstrap with an explicit target#155771
chenyukang wants to merge 1 commit intorust-lang:mainfrom
chenyukang:yukang-fix-155651-bootstrap-build-target

Conversation

@chenyukang
Copy link
Copy Markdown
Member

@chenyukang chenyukang commented Apr 25, 2026

Fixes #155651

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) labels Apr 25, 2026
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Apr 25, 2026

r? @Mark-Simulacrum

rustbot has assigned @Mark-Simulacrum.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: bootstrap
  • bootstrap expanded to 6 candidates
  • Random selection from Mark-Simulacrum, clubby789, jieyouxu

@Kobzol
Copy link
Copy Markdown
Member

Kobzol commented Apr 25, 2026

This sounds like a hack to make bootstrap match a specific kind of Cargo config. We should instead ask Cargo where was the generated binary stored, or use cargo run, or something like that.

@chenyukang chenyukang force-pushed the yukang-fix-155651-bootstrap-build-target branch 2 times, most recently from 8d9b418 to dfe540e Compare April 25, 2026 11:06
@chenyukang chenyukang closed this Apr 25, 2026
@chenyukang chenyukang force-pushed the yukang-fix-155651-bootstrap-build-target branch from dfe540e to 7e0430f Compare April 25, 2026 12:00
@rustbot rustbot removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Apr 25, 2026
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Apr 25, 2026

This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed.

Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers.

@chenyukang
Copy link
Copy Markdown
Member Author

chenyukang commented Apr 25, 2026

oh, I did something wrong on Git and closed it.

@chenyukang chenyukang reopened this Apr 25, 2026
@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Apr 25, 2026
@rust-log-analyzer

This comment has been minimized.

@chenyukang chenyukang force-pushed the yukang-fix-155651-bootstrap-build-target branch from 12db296 to d46bb0d Compare April 25, 2026 13:00
@rust-log-analyzer
Copy link
Copy Markdown
Collaborator

The job tidy failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
   0: __rustc::rust_begin_unwind
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/std/src/panicking.rs:689:5
   1: core::panicking::panic_fmt
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/panicking.rs:80:14
   2: bootstrap::core::download::download_toolchain::<&bootstrap::core::download::DownloadContext>
             at ./src/bootstrap/src/utils/helpers.rs:55:23
   3: bootstrap::core::download::download_beta_toolchain::<&bootstrap::core::download::DownloadContext>
             at ./src/bootstrap/src/core/download.rs:590:5
   4: <bootstrap::core::config::config::Config>::parse_inner::<<bootstrap::core::config::config::Config>::get_toml>::{closure#10}
             at ./src/bootstrap/src/core/config/config.rs:761:13
   5: <core::option::Option<std::path::PathBuf>>::unwrap_or_else::<<bootstrap::core::config::config::Config>::parse_inner<<bootstrap::core::config::config::Config>::get_toml>::{closure#10}>
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/option.rs:1067:21
   6: <bootstrap::core::config::config::Config>::parse_inner::<<bootstrap::core::config::config::Config>::get_toml>
             at ./src/bootstrap/src/core/config/config.rs:760:41
   7: <bootstrap::core::config::config::Config>::parse
             at ./src/bootstrap/src/core/config/config.rs:351:9
   8: bootstrap::main
             at ./src/bootstrap/src/bin/main.rs:39:18
   9: <fn() as core::ops::function::FnOnce<()>>::call_once
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/ops/function.rs:250:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
---
   0: __rustc::rust_begin_unwind
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/std/src/panicking.rs:689:5
   1: core::panicking::panic_fmt
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/panicking.rs:80:14
   2: bootstrap::core::download::download_toolchain::<&bootstrap::core::download::DownloadContext>
             at ./src/bootstrap/src/utils/helpers.rs:55:23
   3: bootstrap::core::download::download_beta_toolchain::<&bootstrap::core::download::DownloadContext>
             at ./src/bootstrap/src/core/download.rs:590:5
   4: <bootstrap::core::config::config::Config>::parse_inner::<<bootstrap::core::config::config::Config>::get_toml>::{closure#10}
             at ./src/bootstrap/src/core/config/config.rs:761:13
   5: <core::option::Option<std::path::PathBuf>>::unwrap_or_else::<<bootstrap::core::config::config::Config>::parse_inner<<bootstrap::core::config::config::Config>::get_toml>::{closure#10}>
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/option.rs:1067:21
   6: <bootstrap::core::config::config::Config>::parse_inner::<<bootstrap::core::config::config::Config>::get_toml>
             at ./src/bootstrap/src/core/config/config.rs:760:41
   7: <bootstrap::core::config::config::Config>::parse
             at ./src/bootstrap/src/core/config/config.rs:351:9
   8: bootstrap::main
             at ./src/bootstrap/src/bin/main.rs:39:18
   9: <fn() as core::ops::function::FnOnce<()>>::call_once
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/ops/function.rs:250:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
---
   0: __rustc::rust_begin_unwind
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/std/src/panicking.rs:689:5
   1: core::panicking::panic_fmt
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/panicking.rs:80:14
   2: bootstrap::core::download::download_toolchain::<&bootstrap::core::download::DownloadContext>
             at ./src/bootstrap/src/utils/helpers.rs:55:23
   3: bootstrap::core::download::download_beta_toolchain::<&bootstrap::core::download::DownloadContext>
             at ./src/bootstrap/src/core/download.rs:590:5
   4: <bootstrap::core::config::config::Config>::parse_inner::<<bootstrap::core::config::config::Config>::get_toml>::{closure#10}
             at ./src/bootstrap/src/core/config/config.rs:761:13
   5: <core::option::Option<std::path::PathBuf>>::unwrap_or_else::<<bootstrap::core::config::config::Config>::parse_inner<<bootstrap::core::config::config::Config>::get_toml>::{closure#10}>
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/option.rs:1067:21
   6: <bootstrap::core::config::config::Config>::parse_inner::<<bootstrap::core::config::config::Config>::get_toml>
             at ./src/bootstrap/src/core/config/config.rs:760:41
   7: <bootstrap::core::config::config::Config>::parse
             at ./src/bootstrap/src/core/config/config.rs:351:9
   8: bootstrap::main
             at ./src/bootstrap/src/bin/main.rs:39:18
   9: <fn() as core::ops::function::FnOnce<()>>::call_once
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/ops/function.rs:250:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
---
   0: __rustc::rust_begin_unwind
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/std/src/panicking.rs:689:5
   1: core::panicking::panic_fmt
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/panicking.rs:80:14
   2: bootstrap::core::download::download_toolchain::<&bootstrap::core::download::DownloadContext>
             at ./src/bootstrap/src/utils/helpers.rs:55:23
   3: bootstrap::core::download::download_beta_toolchain::<&bootstrap::core::download::DownloadContext>
             at ./src/bootstrap/src/core/download.rs:590:5
   4: <bootstrap::core::config::config::Config>::parse_inner::<<bootstrap::core::config::config::Config>::get_toml>::{closure#10}
             at ./src/bootstrap/src/core/config/config.rs:761:13
   5: <core::option::Option<std::path::PathBuf>>::unwrap_or_else::<<bootstrap::core::config::config::Config>::parse_inner<<bootstrap::core::config::config::Config>::get_toml>::{closure#10}>
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/option.rs:1067:21
   6: <bootstrap::core::config::config::Config>::parse_inner::<<bootstrap::core::config::config::Config>::get_toml>
             at ./src/bootstrap/src/core/config/config.rs:760:41
   7: <bootstrap::core::config::config::Config>::parse
             at ./src/bootstrap/src/core/config/config.rs:351:9
   8: bootstrap::main
             at ./src/bootstrap/src/bin/main.rs:39:18
   9: <fn() as core::ops::function::FnOnce<()>>::call_once
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/ops/function.rs:250:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
---
   0: __rustc::rust_begin_unwind
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/std/src/panicking.rs:689:5
   1: core::panicking::panic_fmt
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/panicking.rs:80:14
   2: bootstrap::core::download::download_toolchain::<&bootstrap::core::download::DownloadContext>
             at ./src/bootstrap/src/utils/helpers.rs:55:23
   3: bootstrap::core::download::download_beta_toolchain::<&bootstrap::core::download::DownloadContext>
             at ./src/bootstrap/src/core/download.rs:590:5
   4: <bootstrap::core::config::config::Config>::parse_inner::<<bootstrap::core::config::config::Config>::get_toml>::{closure#10}
             at ./src/bootstrap/src/core/config/config.rs:761:13
   5: <core::option::Option<std::path::PathBuf>>::unwrap_or_else::<<bootstrap::core::config::config::Config>::parse_inner<<bootstrap::core::config::config::Config>::get_toml>::{closure#10}>
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/option.rs:1067:21
   6: <bootstrap::core::config::config::Config>::parse_inner::<<bootstrap::core::config::config::Config>::get_toml>
             at ./src/bootstrap/src/core/config/config.rs:760:41
   7: <bootstrap::core::config::config::Config>::parse
             at ./src/bootstrap/src/core/config/config.rs:351:9
   8: bootstrap::main
             at ./src/bootstrap/src/bin/main.rs:39:18
   9: <fn() as core::ops::function::FnOnce<()>>::call_once
             at /rustc/ef0fb8a2563200e322fa4419f09f65a63742038c/library/core/src/ops/function.rs:250:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

x.py fails if .cargo/config configures build.target

5 participants