File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -575,6 +575,9 @@ where
575
575
} ;
576
576
if split_dwarf {
577
577
let dwo = output. with_extension ( "dwo" ) ;
578
+ common_args. push ( OsString :: from (
579
+ "-D_gsplit_dwarf_path=" . to_owned ( ) + dwo. to_str ( ) . unwrap ( ) ,
580
+ ) ) ;
578
581
// -gsplit-dwarf doesn't guarantee .dwo file if no -g is specified
579
582
outputs. insert (
580
583
"dwo" ,
@@ -1075,6 +1078,9 @@ mod test {
1075
1078
CompilerArguments :: Ok ( args) => args,
1076
1079
o => panic ! ( "Got unexpected parse result: {:?}" , o) ,
1077
1080
} ;
1081
+ let mut common_and_arch_args = common_args. clone ( ) ;
1082
+ common_and_arch_args. extend ( common_args. to_vec ( ) ) ;
1083
+ debug ! ( "common_and_arch_args: {:?}" , common_and_arch_args) ;
1078
1084
assert_eq ! ( Some ( "foo.cpp" ) , input. to_str( ) ) ;
1079
1085
assert_eq ! ( Language :: Cxx , language) ;
1080
1086
assert_map_contains ! (
@@ -1095,7 +1101,10 @@ mod test {
1095
1101
)
1096
1102
) ;
1097
1103
assert ! ( preprocessor_args. is_empty( ) ) ;
1098
- assert_eq ! ( ovec![ "-gsplit-dwarf" ] , common_args) ;
1104
+ assert ! (
1105
+ common_args. contains( & "-gsplit-dwarf" . into( ) )
1106
+ && common_args. contains( & "-D_gsplit_dwarf_path=foo.dwo" . into( ) )
1107
+ ) ;
1099
1108
assert ! ( !msvc_show_includes) ;
1100
1109
}
1101
1110
You can’t perform that action at this time.
0 commit comments