File tree 1 file changed +2
-4
lines changed
src/cargo/core/compiler/build_context
1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -694,19 +694,17 @@ impl<'cfg> RustcTargetData<'cfg> {
694
694
} else {
695
695
config. host_cfg_triple ( & rustc. host ) ?
696
696
} ;
697
+ let is_cross = !requested_kinds. iter ( ) . any ( CompileKind :: is_host) ;
697
698
698
699
// This is a hack. The unit_dependency graph builder "pretends" that
699
700
// `CompileKind::Host` is `CompileKind::Target(host)` if the
700
701
// `--target` flag is not specified. Since the unit_dependency code
701
702
// needs access to the target config data, create a copy so that it
702
703
// can be found. See `rebuild_unit_graph_shared` for why this is done.
703
- let is_cross = if requested_kinds . iter ( ) . any ( CompileKind :: is_host ) {
704
+ if !is_cross {
704
705
let ct = CompileTarget :: new ( & rustc. host ) ?;
705
706
target_info. insert ( ct, host_info. clone ( ) ) ;
706
707
target_config. insert ( ct, config. target_cfg_triple ( & rustc. host ) ?) ;
707
- false
708
- } else {
709
- true
710
708
} ;
711
709
712
710
let mut res = RustcTargetData {
You can’t perform that action at this time.
0 commit comments