about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/bootstrap/step.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/bootstrap/step.rs b/src/bootstrap/step.rs
index 4c1f58e52d9..c5516f26fb4 100644
--- a/src/bootstrap/step.rs
+++ b/src/bootstrap/step.rs
@@ -148,6 +148,14 @@ pub fn build_rules(build: &Build) -> Rules {
              });
     }
     for (krate, path, default) in krates("rustc-main") {
+        // We hijacked the `src/rustc` path above for "build just the compiler"
+        // so let's not reinterpret it here as everything and redirect the
+        // `src/rustc` path to a nonexistent path.
+        let path = if path == "src/rustc" {
+            "path/to/nowhere"
+        } else {
+            path
+        };
         rules.build(&krate.build_step, path)
              .dep(|s| s.name("libtest"))
              .dep(move |s| s.name("llvm").host(&build.config.build).stage(0))