File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -815,7 +815,7 @@ impl<'a> Builder<'a> {
815815 stage = compiler. stage ;
816816 }
817817
818- let mut rustflags = Rustflags :: new ( & target, & mut cargo ) ;
818+ let mut rustflags = Rustflags :: new ( & target) ;
819819 if stage != 0 {
820820 rustflags. env ( "RUSTFLAGS_NOT_BOOTSTRAP" ) ;
821821 } else {
@@ -1339,18 +1339,16 @@ mod tests;
13391339struct Rustflags ( String ) ;
13401340
13411341impl Rustflags {
1342- fn new ( target : & str , cmd : & mut Command ) -> Rustflags {
1342+ fn new ( target : & str ) -> Rustflags {
13431343 let mut ret = Rustflags ( String :: new ( ) ) ;
13441344
13451345 // Inherit `RUSTFLAGS` by default ...
13461346 ret. env ( "RUSTFLAGS" ) ;
13471347
13481348 // ... and also handle target-specific env RUSTFLAGS if they're
1349- // configured. If this is configured we also remove it from the
1350- // environment because Cargo will prefer it over RUSTFLAGS.
1349+ // configured.
13511350 let target_specific = format ! ( "CARGO_TARGET_{}_RUSTFLAGS" , crate :: envify( target) ) ;
13521351 ret. env ( & target_specific) ;
1353- cmd. env_remove ( & target_specific) ;
13541352
13551353 ret
13561354 }
You can’t perform that action at this time.
0 commit comments