fixes for win32

This commit is contained in:
Andrea Fioraldi 2021-03-18 16:35:02 +01:00
parent 1e7a5ebe81
commit acdc70b0a6
3 changed files with 3 additions and 4 deletions

View File

@ -63,8 +63,8 @@ nix = "0.20.0"
uds = "0.2.3" uds = "0.2.3"
[target.'cfg(windows)'.dependencies] [target.'cfg(windows)'.dependencies]
windows = "0.3.1" windows = "0.4.0"
uuid = { version = "0.8", features = ["v4"] } uuid = { version = "0.8", features = ["v4"] }
[target.'cfg(windows)'.build-dependencies] [target.'cfg(windows)'.build-dependencies]
windows = "0.3.1" windows = "0.4.0"

View File

@ -1,7 +1,7 @@
fn main() { fn main() {
#[cfg(target_os = "windows")] #[cfg(target_os = "windows")]
windows::build!( windows::build!(
windows::win32::system_services::HANDLE, windows::win32::system_services::{HANDLE, BOOL, PAGE_TYPE},
windows::win32::windows_programming::CloseHandle, windows::win32::windows_programming::CloseHandle,
// API needed for the shared memory // API needed for the shared memory
windows::win32::system_services::{CreateFileMappingA, OpenFileMappingA, MapViewOfFile, UnmapViewOfFile}, windows::win32::system_services::{CreateFileMappingA, OpenFileMappingA, MapViewOfFile, UnmapViewOfFile},

View File

@ -460,7 +460,6 @@ pub mod shmem {
const INVALID_HANDLE_VALUE: isize = -1; const INVALID_HANDLE_VALUE: isize = -1;
const FILE_MAP_ALL_ACCESS: u32 = 0xf001f; const FILE_MAP_ALL_ACCESS: u32 = 0xf001f;
//const PAGE_READWRITE: u32 = 0x04;
/// The default Sharedmap impl for windows using shmctl & shmget /// The default Sharedmap impl for windows using shmctl & shmget
#[derive(Clone, Debug)] #[derive(Clone, Debug)]