fn find_msvc_latest(arch: &str, ver: &str) -> Option<(Command, PathBuf)> {
        let vcdir = otry!(get_vc_dir(ver));
        let (mut cmd, host) = otry!(get_linker(&vcdir, arch));
        let sub = otry!(lib_subdir(arch));
        let ucrt = otry!(get_ucrt_dir());
        debug!("Found Universal CRT {:?}", ucrt);
        add_lib(&mut cmd, &ucrt.join("ucrt").join(sub));
        if let Some(dir) = get_sdk10_dir() {
            debug!("Found Win10 SDK {:?}", dir);
            add_lib(&mut cmd, &dir.join("um").join(sub));
        } else if let Some(dir) = get_sdk81_dir() {
            debug!("Found Win8.1 SDK {:?}", dir);
            add_lib(&mut cmd, &dir.join("um").join(sub));
        } else {
            return None
        }
        Some((cmd, host))
    }
// For MSVC 14 or newer we need to find the Universal CRT as well as either
// the Windows 10 SDK or Windows 8.1 SDK.
For MSVC 14 or newer we need to find the Universal CRT as well as either
the Windows 10 SDK or Windows 8.1 SDK.
For MSVC 14 or newer we need to find the Universal CRT as well as either the Windows 10 SDK or Windows 8 . 1 SDK .
fn find_msvc_latest(arch: &str, ver: &str) -> Option<(Command, PathBuf)> {
        let vcdir = otry!(get_vc_dir(ver));
        let (mut cmd, host) = otry!(get_linker(&vcdir, arch));
        let sub = otry!(lib_subdir(arch));
        let ucrt = otry!(get_ucrt_dir());
        debug!("Found Universal CRT {:?}", ucrt);
        add_lib(&mut cmd, &ucrt.join("ucrt").join(sub));
        if let Some(dir) = get_sdk10_dir() {
            debug!("Found Win10 SDK {:?}", dir);
            add_lib(&mut cmd, &dir.join("um").join(sub));
        } else if let Some(dir) = get_sdk81_dir() {
            debug!("Found Win8.1 SDK {:?}", dir);
            add_lib(&mut cmd, &dir.join("um").join(sub));
        } else {
            return None
        }
        Some((cmd, host))
    }
fn find_msvc_latest ( arch : & str , ver : & str ) -> Option < ( Command , PathBuf ) > { let vcdir = otry ! ( get_vc_dir ( ver ) ) ; let ( mut cmd , host ) = otry ! ( get_linker ( vcdir arch ) ) ; let sub = otry ! ( lib_subdir ( arch ) ) ; let ucrt = otry ! ( get_ucrt_dir ( ) ) ; debug ! ( " " ucrt ) ; add_lib ( & mut cmd , & ucrt . join ( " " ) . join ( sub ) ) ; if let Some ( dir ) = get_sdk10_dir ( ) { debug ! ( " " dir ) ; add_lib ( & mut cmd , & dir . join ( " " ) . join ( sub ) ) ; } else if let Some ( dir ) = get_sdk81_dir ( ) { debug ! ( " " dir ) ; add_lib ( & mut cmd , & dir . join ( " " ) . join ( sub ) ) ; } else { return None } Some ( ( cmd , host ) ) }
For MSVC 14 or newer we need to find the Universal CRT as well as either
the Windows 10 SDK or Windows 8.1 SDK.
For MSVC 14 or newer we need to find the Universal CRT as well as either the Windows 10 SDK or Windows 8 . 1 SDK .
arch
&str
ver
&str
arch
&str
ver
&str