File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed
Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -199,11 +199,19 @@ fn get_boringssl_cmake_config(config: &Config) -> cmake::Config {
199199 let src_path = get_boringssl_source_path ( config) ;
200200 let mut boringssl_cmake = cmake:: Config :: new ( src_path) ;
201201
202- if config. host == config . target {
202+ if config. env . cmake_toolchain_file . is_some ( ) {
203203 return boringssl_cmake;
204204 }
205205
206- if config. env . cmake_toolchain_file . is_some ( ) {
206+ if config. target_os == "windows" {
207+ // Explicitly use the non-debug CRT.
208+ // This is required now because newest BoringSSL requires CMake 3.22 which
209+ // uses the new logic with CMAKE_MSVC_RUNTIME_LIBRARY introduced in CMake 3.15.
210+ // https://github.com/rust-lang/cmake-rs/pull/30#issuecomment-2969758499
211+ boringssl_cmake. define ( "CMAKE_MSVC_RUNTIME_LIBRARY" , "MultiThreadedDLL" ) ;
212+ }
213+
214+ if config. host == config. target {
207215 return boringssl_cmake;
208216 }
209217
You can’t perform that action at this time.
0 commit comments