Skip to content

Commit 9979b16

Browse files
authored
Rollup merge of rust-lang#52969 - Keruspe:local_rebuild, r=alexcrichton
rustbuild: fix local_rebuild If we detect a local rebuild (e.g. bootstrap compiler is the same version as target compiler), we set stage to 1. When trying to build e.g. UnstableBook, we use Mode::ToolBootstrap and stage is 1. Just allow Mode::ToolBootstrap and stagge != 0 if we are in a local_rebuild This fixes building current master using current beta (as master hasn't yet been bumped to 1.30). This should be backported to beta too, as currently we cannot build beta using itself because of that. r? @alexcrichton
2 parents 4889e0f + 66a4718 commit 9979b16

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/bootstrap/builder.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -778,7 +778,7 @@ impl<'a> Builder<'a> {
778778
// compiler, but for tools we just use the precompiled libraries that
779779
// we've downloaded
780780
let use_snapshot = mode == Mode::ToolBootstrap;
781-
assert!(!use_snapshot || stage == 0);
781+
assert!(!use_snapshot || stage == 0 || self.local_rebuild);
782782

783783
let maybe_sysroot = self.sysroot(compiler);
784784
let sysroot = if use_snapshot {

0 commit comments

Comments
 (0)