File tree 1 file changed +4
-2
lines changed
src/tools/compiletest/src
1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -385,7 +385,8 @@ impl Config {
385
385
}
386
386
387
387
fn target_cfg ( & self ) -> & TargetCfg {
388
- self . target_cfg . borrow_with ( || TargetCfg :: new ( & self . rustc_path , & self . target ) )
388
+ self . target_cfg
389
+ . borrow_with ( || TargetCfg :: new ( & self . rustc_path , & self . target , & self . target_rustcflags ) )
389
390
}
390
391
391
392
pub fn matches_arch ( & self , arch : & str ) -> bool {
@@ -456,11 +457,12 @@ pub enum Endian {
456
457
}
457
458
458
459
impl TargetCfg {
459
- fn new ( rustc_path : & Path , target : & str ) -> TargetCfg {
460
+ fn new ( rustc_path : & Path , target : & str , target_rustcflags : & Option < String > ) -> TargetCfg {
460
461
let output = match Command :: new ( rustc_path)
461
462
. arg ( "--print=cfg" )
462
463
. arg ( "--target" )
463
464
. arg ( target)
465
+ . args ( target_rustcflags. into_iter ( ) . map ( |s| s. split_whitespace ( ) ) . flatten ( ) )
464
466
. output ( )
465
467
{
466
468
Ok ( output) => output,
You can’t perform that action at this time.
0 commit comments