diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2020-05-31 16:03:57 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-31 16:03:57 +0000 |
commit | 84e66d7a29234d16d62c5fa5bc5b66ad5504c2a2 (patch) | |
tree | 6d41c93aa22c24489f11d885c8470d25c9564a7d /src/sys/event.rs | |
parent | d950c481abe5fb11cdbd648c67c8022c6c209664 (diff) | |
parent | efef981f6642bf7ae6d0f6d69118e5826adc2156 (diff) | |
download | nix-84e66d7a29234d16d62c5fa5bc5b66ad5504c2a2.zip |
Merge #1252
1252: Add EV_DISPATCH, EV_RECEIPT items for EventFlags, and fix build on OpenBSD r=asomers a=nickpelone
This pull request:
- Adds `EV_DISPATCH` and `EV_RECEIPT` to `EventFlags`. OpenBSD supports these now.
c379d1a
- Fixes a regression that caused `nix` to be unable to build on OpenBSD since #1208.
dd0a990
- Makes a change to avoid a deprecation warning from `libc` crate, which breaks tests.
0f9fcbd
Since I know y'all don't have OpenBSD in CI right now, I've attached the results of a `cargo test` run on OpenBSD 6.7.
Thanks for your time!
[testresults.txt](https://github.com/nix-rust/nix/files/4684597/testresults.txt)
Fixes #1251
Co-authored-by: Nick Pelone <nick.pelone@calyptix.com>
Diffstat (limited to 'src/sys/event.rs')
-rw-r--r-- | src/sys/event.rs | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/src/sys/event.rs b/src/sys/event.rs index 7af5ae2b..cf9393bd 100644 --- a/src/sys/event.rs +++ b/src/sys/event.rs @@ -28,7 +28,7 @@ type type_of_data = intptr_t; #[cfg(any(target_os = "netbsd"))] type type_of_udata = intptr_t; #[cfg(any(target_os = "netbsd", target_os = "openbsd"))] -type type_of_data = libc::int64_t; +type type_of_data = i64; #[cfg(target_os = "netbsd")] type type_of_event_filter = u32; @@ -90,14 +90,9 @@ libc_bitflags!{ EV_CLEAR; EV_DELETE; EV_DISABLE; - // No released version of OpenBSD supports EV_DISPATCH or EV_RECEIPT. - // These have been commited to the -current branch though and are - // expected to be part of the OpenBSD 6.2 release in Nov 2017. - // See: https://marc.info/?l=openbsd-tech&m=149621427511219&w=2 - // https://github.com/rust-lang/libc/pull/613 #[cfg(any(target_os = "dragonfly", target_os = "freebsd", target_os = "ios", target_os = "macos", - target_os = "netbsd"))] + target_os = "netbsd", target_os = "openbsd"))] EV_DISPATCH; #[cfg(target_os = "freebsd")] EV_DROP; @@ -116,7 +111,7 @@ libc_bitflags!{ EV_POLL; #[cfg(any(target_os = "dragonfly", target_os = "freebsd", target_os = "ios", target_os = "macos", - target_os = "netbsd"))] + target_os = "netbsd", target_os = "openbsd"))] EV_RECEIPT; EV_SYSFLAGS; } |