@@ -115,7 +115,7 @@ impl Step for JsonDocs {
115115 /// Builds the `rust-docs-json` installer component.
116116 fn run ( self , builder : & Builder < ' _ > ) -> Option < GeneratedTarball > {
117117 let target = self . target ;
118- builder. ensure ( crate :: core:: build_steps:: doc:: Std :: from_build_compiler (
118+ let directory = builder. ensure ( crate :: core:: build_steps:: doc:: Std :: from_build_compiler (
119119 self . build_compiler ,
120120 target,
121121 DocumentationFormat :: Json ,
@@ -126,7 +126,7 @@ impl Step for JsonDocs {
126126 let mut tarball = Tarball :: new ( builder, "rust-docs-json" , & target. triple ) ;
127127 tarball. set_product_name ( "Rust Documentation In JSON Format" ) ;
128128 tarball. is_preview ( true ) ;
129- tarball. add_bulk_dir ( builder . json_doc_out ( target ) , dest) ;
129+ tarball. add_bulk_dir ( directory , dest) ;
130130 Some ( tarball. generate ( ) )
131131 }
132132}
@@ -1589,19 +1589,21 @@ impl Step for Extended {
15891589 } ;
15901590 }
15911591
1592+ let target_compiler = builder. compiler ( stage, target) ;
15921593 // When rust-std package split from rustc, we needed to ensure that during
15931594 // upgrades rustc was upgraded before rust-std. To avoid rustc clobbering
15941595 // the std files during uninstall. To do this ensure that rustc comes
15951596 // before rust-std in the list below.
1596- tarballs. push ( builder. ensure ( Rustc { compiler : builder . compiler ( stage , target ) } ) ) ;
1597+ tarballs. push ( builder. ensure ( Rustc { compiler : target_compiler } ) ) ;
15971598 tarballs. push ( builder. ensure ( Std { compiler, target } ) . expect ( "missing std" ) ) ;
15981599
15991600 if target. is_windows_gnu ( ) {
16001601 tarballs. push ( builder. ensure ( Mingw { host : target } ) . expect ( "missing mingw" ) ) ;
16011602 }
16021603
16031604 add_component ! ( "rust-docs" => Docs { host: target } ) ;
1604- add_component ! ( "rust-json-docs" => JsonDocs { build_compiler: compiler, target } ) ;
1605+ // Std stage N is documented with compiler stage N
1606+ add_component ! ( "rust-json-docs" => JsonDocs { build_compiler: target_compiler, target } ) ;
16051607 add_component ! ( "cargo" => Cargo { build_compiler: compiler, target } ) ;
16061608 add_component ! ( "rustfmt" => Rustfmt { build_compiler: compiler, target } ) ;
16071609 add_component ! ( "rust-analyzer" => RustAnalyzer { build_compiler: compiler, target } ) ;
0 commit comments