@@ -69,23 +69,10 @@ use std::thread::{self, JoinHandle};
69
69
mod os_pipe;
70
70
#[ cfg( feature = "parallel" ) ]
71
71
mod parallel;
72
- // These modules are all glue to support reading the MSVC version from
73
- // the registry and from COM interfaces
74
- #[ cfg( windows) ]
75
- mod registry;
76
- #[ cfg( windows) ]
77
- #[ macro_use]
78
- mod winapi;
79
- #[ cfg( windows) ]
80
- mod com;
81
- #[ cfg( windows) ]
82
- mod setup_config;
83
- #[ cfg( windows) ]
84
- mod vs_instances;
85
- #[ cfg( windows) ]
86
- mod windows_sys;
87
-
88
- pub mod windows_registry;
72
+ mod windows;
73
+ // Regardless of whether this should be in this crate's public API,
74
+ // it has been since 2015, so don't break it.
75
+ pub use windows:: find_tools as windows_registry;
89
76
90
77
/// A builder for compilation of a native library.
91
78
///
@@ -2198,7 +2185,7 @@ impl Build {
2198
2185
} else {
2199
2186
"ml.exe"
2200
2187
} ;
2201
- let mut cmd = windows_registry :: find ( & target, tool) . unwrap_or_else ( || self . cmd ( tool) ) ;
2188
+ let mut cmd = windows :: find_tools :: find ( & target, tool) . unwrap_or_else ( || self . cmd ( tool) ) ;
2202
2189
cmd. arg ( "-nologo" ) ; // undocumented, yet working with armasm[64]
2203
2190
for directory in self . include_directories . iter ( ) {
2204
2191
cmd. arg ( "-I" ) . arg ( & * * directory) ;
@@ -2554,7 +2541,7 @@ impl Build {
2554
2541
traditional
2555
2542
} ;
2556
2543
2557
- let cl_exe = windows_registry :: find_tool ( target, "cl.exe" ) ;
2544
+ let cl_exe = windows :: find_tools :: find_tool ( target, "cl.exe" ) ;
2558
2545
2559
2546
let tool_opt: Option < Tool > = self
2560
2547
. env_tool ( env)
@@ -3025,7 +3012,7 @@ impl Build {
3025
3012
3026
3013
if lib. is_empty ( ) {
3027
3014
name = String :: from ( "lib.exe" ) ;
3028
- let mut cmd = match windows_registry :: find ( & target, "lib.exe" ) {
3015
+ let mut cmd = match windows :: find_tools :: find ( & target, "lib.exe" ) {
3029
3016
Some ( t) => t,
3030
3017
None => self . cmd ( "lib.exe" ) ,
3031
3018
} ;
0 commit comments