about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authoronur-ozkan <work@onurozkan.dev>2025-03-05 09:26:25 +0300
committeronur-ozkan <work@onurozkan.dev>2025-03-05 13:29:41 +0300
commit9e4b3d6bc4dc9c3d5bbf65511212791fa32666ac (patch)
tree369c406a281f1cf516ca7d6a32d255898591aa71 /src
parentb885407c0ce3cfdc7bc91c108b41e2026b51de5a (diff)
downloadrust-9e4b3d6bc4dc9c3d5bbf65511212791fa32666ac.tar.gz
rust-9e4b3d6bc4dc9c3d5bbf65511212791fa32666ac.zip
handle forced compiler in `get_tool_rustc_compiler`
Signed-off-by: onur-ozkan <work@onurozkan.dev>
Diffstat (limited to 'src')
-rw-r--r--src/bootstrap/src/core/build_steps/tool.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/bootstrap/src/core/build_steps/tool.rs b/src/bootstrap/src/core/build_steps/tool.rs
index 39acb646dff..e86bf02e9c3 100644
--- a/src/bootstrap/src/core/build_steps/tool.rs
+++ b/src/bootstrap/src/core/build_steps/tool.rs
@@ -299,6 +299,8 @@ pub(crate) fn get_tool_rustc_compiler(
     if builder.download_rustc() && target_compiler.stage == 1 {
         // We already have the stage 1 compiler, we don't need to cut the stage.
         builder.compiler(target_compiler.stage, builder.config.build)
+    } else if target_compiler.is_forced_compiler() {
+        target_compiler
     } else {
         // Similar to `compile::Assemble`, build with the previous stage's compiler. Otherwise
         // we'd have stageN/bin/rustc and stageN/bin/$rustc_tool be effectively different stage