13
13
//! (as usual) a massive undertaking/refactoring.
14
14
15
15
use super :: compile:: { run_cargo, rustc_cargo, std_cargo} ;
16
- use super :: tool:: { RustcPrivateCompilers , SourceType , prepare_tool_cargo} ;
16
+ use super :: tool:: { SourceType , prepare_tool_cargo} ;
17
17
use crate :: builder:: { Builder , ShouldRun } ;
18
18
use crate :: core:: build_steps:: check:: prepare_compiler_for_check;
19
19
use crate :: core:: build_steps:: compile:: std_crates_for_run_make;
@@ -306,15 +306,15 @@ impl Step for Rustc {
306
306
307
307
#[ derive( Debug , Clone , Hash , PartialEq , Eq ) ]
308
308
pub struct CodegenGcc {
309
- compilers : RustcPrivateCompilers ,
309
+ build_compiler : Compiler ,
310
310
target : TargetSelection ,
311
311
config : LintConfig ,
312
312
}
313
313
314
314
impl CodegenGcc {
315
315
fn new ( builder : & Builder < ' _ > , target : TargetSelection , config : LintConfig ) -> Self {
316
316
Self {
317
- compilers : RustcPrivateCompilers :: new ( builder, builder . top_stage , target ) ,
317
+ build_compiler : prepare_compiler_for_check ( builder, target , Mode :: Codegen ) ,
318
318
target,
319
319
config,
320
320
}
@@ -335,7 +335,7 @@ impl Step for CodegenGcc {
335
335
}
336
336
337
337
fn run ( self , builder : & Builder < ' _ > ) -> Self :: Output {
338
- let build_compiler = self . compilers . build_compiler ( ) ;
338
+ let build_compiler = self . build_compiler ;
339
339
let target = self . target ;
340
340
341
341
let cargo = prepare_tool_cargo (
@@ -367,10 +367,7 @@ impl Step for CodegenGcc {
367
367
}
368
368
369
369
fn metadata ( & self ) -> Option < StepMetadata > {
370
- Some (
371
- StepMetadata :: clippy ( "rustc_codegen_gcc" , self . target )
372
- . built_by ( self . compilers . build_compiler ( ) ) ,
373
- )
370
+ Some ( StepMetadata :: clippy ( "rustc_codegen_gcc" , self . target ) . built_by ( self . build_compiler ) )
374
371
}
375
372
}
376
373
0 commit comments