mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-25 16:24:46 +00:00
bump windows crate 0.46 -> 0.48 in workspace
This commit is contained in:
parent
7e7483d26e
commit
3c03cce341
23
Cargo.lock
23
Cargo.lock
@ -741,7 +741,7 @@ dependencies = [
|
|||||||
"tracing-subscriber",
|
"tracing-subscriber",
|
||||||
"unified-diff",
|
"unified-diff",
|
||||||
"walkdir",
|
"walkdir",
|
||||||
"windows 0.46.0",
|
"windows",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
@ -1647,7 +1647,7 @@ dependencies = [
|
|||||||
"iana-time-zone-haiku",
|
"iana-time-zone-haiku",
|
||||||
"js-sys",
|
"js-sys",
|
||||||
"wasm-bindgen",
|
"wasm-bindgen",
|
||||||
"windows 0.48.0",
|
"windows",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
@ -3259,7 +3259,7 @@ dependencies = [
|
|||||||
"tempfile",
|
"tempfile",
|
||||||
"thorin-dwp",
|
"thorin-dwp",
|
||||||
"tracing",
|
"tracing",
|
||||||
"windows 0.46.0",
|
"windows",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
@ -3315,7 +3315,7 @@ dependencies = [
|
|||||||
"tempfile",
|
"tempfile",
|
||||||
"thin-vec",
|
"thin-vec",
|
||||||
"tracing",
|
"tracing",
|
||||||
"windows 0.46.0",
|
"windows",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
@ -3376,7 +3376,7 @@ dependencies = [
|
|||||||
"rustc_ty_utils",
|
"rustc_ty_utils",
|
||||||
"serde_json",
|
"serde_json",
|
||||||
"tracing",
|
"tracing",
|
||||||
"windows 0.46.0",
|
"windows",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
@ -3426,7 +3426,7 @@ dependencies = [
|
|||||||
"termize",
|
"termize",
|
||||||
"tracing",
|
"tracing",
|
||||||
"unicode-width",
|
"unicode-width",
|
||||||
"windows 0.46.0",
|
"windows",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
@ -4096,7 +4096,7 @@ dependencies = [
|
|||||||
"smallvec",
|
"smallvec",
|
||||||
"termize",
|
"termize",
|
||||||
"tracing",
|
"tracing",
|
||||||
"windows 0.46.0",
|
"windows",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
@ -5498,15 +5498,6 @@ version = "0.4.0"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
|
checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "windows"
|
|
||||||
version = "0.46.0"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "cdacb41e6a96a052c6cb63a144f24900236121c6f63f4f8219fef5977ecb0c25"
|
|
||||||
dependencies = [
|
|
||||||
"windows-targets 0.42.2",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "windows"
|
name = "windows"
|
||||||
version = "0.48.0"
|
version = "0.48.0"
|
||||||
|
@ -51,5 +51,5 @@ default-features = false
|
|||||||
features = ["read_core", "elf", "macho", "pe", "unaligned", "archive", "write"]
|
features = ["read_core", "elf", "macho", "pe", "unaligned", "archive", "write"]
|
||||||
|
|
||||||
[target.'cfg(windows)'.dependencies.windows]
|
[target.'cfg(windows)'.dependencies.windows]
|
||||||
version = "0.46.0"
|
version = "0.48.0"
|
||||||
features = ["Win32_Globalization"]
|
features = ["Win32_Globalization"]
|
||||||
|
@ -37,7 +37,7 @@ itertools = "0.10.1"
|
|||||||
version = "0.11"
|
version = "0.11"
|
||||||
|
|
||||||
[target.'cfg(windows)'.dependencies.windows]
|
[target.'cfg(windows)'.dependencies.windows]
|
||||||
version = "0.46.0"
|
version = "0.48.0"
|
||||||
features = [
|
features = [
|
||||||
"Win32_Foundation",
|
"Win32_Foundation",
|
||||||
"Win32_Storage_FileSystem",
|
"Win32_Storage_FileSystem",
|
||||||
|
@ -865,14 +865,16 @@ cfg_if! {
|
|||||||
use std::mem;
|
use std::mem;
|
||||||
|
|
||||||
use windows::{
|
use windows::{
|
||||||
Win32::System::ProcessStatus::{K32GetProcessMemoryInfo, PROCESS_MEMORY_COUNTERS},
|
// FIXME: change back to K32GetProcessMemoryInfo when windows crate
|
||||||
|
// updated to 0.49.0+ to drop dependency on psapi.dll
|
||||||
|
Win32::System::ProcessStatus::{GetProcessMemoryInfo, PROCESS_MEMORY_COUNTERS},
|
||||||
Win32::System::Threading::GetCurrentProcess,
|
Win32::System::Threading::GetCurrentProcess,
|
||||||
};
|
};
|
||||||
|
|
||||||
let mut pmc = PROCESS_MEMORY_COUNTERS::default();
|
let mut pmc = PROCESS_MEMORY_COUNTERS::default();
|
||||||
let pmc_size = mem::size_of_val(&pmc);
|
let pmc_size = mem::size_of_val(&pmc);
|
||||||
unsafe {
|
unsafe {
|
||||||
K32GetProcessMemoryInfo(
|
GetProcessMemoryInfo(
|
||||||
GetCurrentProcess(),
|
GetCurrentProcess(),
|
||||||
&mut pmc,
|
&mut pmc,
|
||||||
pmc_size as u32,
|
pmc_size as u32,
|
||||||
|
@ -57,7 +57,7 @@ rustc_mir_transform = { path = "../rustc_mir_transform" }
|
|||||||
libc = "0.2"
|
libc = "0.2"
|
||||||
|
|
||||||
[target.'cfg(windows)'.dependencies.windows]
|
[target.'cfg(windows)'.dependencies.windows]
|
||||||
version = "0.46.0"
|
version = "0.48.0"
|
||||||
features = [
|
features = [
|
||||||
"Win32_System_Diagnostics_Debug",
|
"Win32_System_Diagnostics_Debug",
|
||||||
]
|
]
|
||||||
|
@ -27,12 +27,11 @@ serde = { version = "1.0.125", features = [ "derive" ] }
|
|||||||
serde_json = "1.0.59"
|
serde_json = "1.0.59"
|
||||||
|
|
||||||
[target.'cfg(windows)'.dependencies.windows]
|
[target.'cfg(windows)'.dependencies.windows]
|
||||||
version = "0.46.0"
|
version = "0.48.0"
|
||||||
features = [
|
features = [
|
||||||
"Win32_Foundation",
|
"Win32_Foundation",
|
||||||
"Win32_Security",
|
"Win32_Security",
|
||||||
"Win32_System_Threading",
|
"Win32_System_Threading",
|
||||||
"Win32_System_WindowsProgramming",
|
|
||||||
]
|
]
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
|
@ -19,8 +19,7 @@ pub fn acquire_global_lock(name: &str) -> Box<dyn Any> {
|
|||||||
use windows::{
|
use windows::{
|
||||||
core::PCSTR,
|
core::PCSTR,
|
||||||
Win32::Foundation::{CloseHandle, HANDLE, WAIT_ABANDONED, WAIT_OBJECT_0},
|
Win32::Foundation::{CloseHandle, HANDLE, WAIT_ABANDONED, WAIT_OBJECT_0},
|
||||||
Win32::System::Threading::{CreateMutexA, ReleaseMutex, WaitForSingleObject},
|
Win32::System::Threading::{CreateMutexA, ReleaseMutex, WaitForSingleObject, INFINITE},
|
||||||
Win32::System::WindowsProgramming::INFINITE,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
struct Handle(HANDLE);
|
struct Handle(HANDLE);
|
||||||
|
@ -25,7 +25,7 @@ termize = "0.1.1"
|
|||||||
libc = "0.2"
|
libc = "0.2"
|
||||||
|
|
||||||
[target.'cfg(windows)'.dependencies.windows]
|
[target.'cfg(windows)'.dependencies.windows]
|
||||||
version = "0.46.0"
|
version = "0.48.0"
|
||||||
features = [
|
features = [
|
||||||
"Win32_Foundation",
|
"Win32_Foundation",
|
||||||
"Win32_System_LibraryLoader",
|
"Win32_System_LibraryLoader",
|
||||||
|
@ -135,13 +135,13 @@ fn current_dll_path() -> Result<PathBuf, String> {
|
|||||||
|
|
||||||
use windows::{
|
use windows::{
|
||||||
core::PCWSTR,
|
core::PCWSTR,
|
||||||
Win32::Foundation::HINSTANCE,
|
Win32::Foundation::HMODULE,
|
||||||
Win32::System::LibraryLoader::{
|
Win32::System::LibraryLoader::{
|
||||||
GetModuleFileNameW, GetModuleHandleExW, GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS,
|
GetModuleFileNameW, GetModuleHandleExW, GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS,
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
let mut module = HINSTANCE::default();
|
let mut module = HMODULE::default();
|
||||||
unsafe {
|
unsafe {
|
||||||
GetModuleHandleExW(
|
GetModuleHandleExW(
|
||||||
GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS,
|
GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS,
|
||||||
|
@ -28,7 +28,7 @@ libc = "0.2"
|
|||||||
miow = "0.5"
|
miow = "0.5"
|
||||||
|
|
||||||
[target.'cfg(windows)'.dependencies.windows]
|
[target.'cfg(windows)'.dependencies.windows]
|
||||||
version = "0.46.0"
|
version = "0.48.0"
|
||||||
features = [
|
features = [
|
||||||
"Win32_Foundation",
|
"Win32_Foundation",
|
||||||
"Win32_System_Diagnostics_Debug",
|
"Win32_System_Diagnostics_Debug",
|
||||||
|
Loading…
Reference in New Issue
Block a user