diff options
author | Alan Somers <asomers@gmail.com> | 2019-06-02 21:16:53 -0600 |
---|---|---|
committer | Alan Somers <asomers@gmail.com> | 2019-06-02 21:43:13 -0600 |
commit | 3c992d400af6162c8ac39de11d5750180b857322 (patch) | |
tree | 37644e0370e4f71d4d6a5572cf52f1cdbc9d82f3 /src | |
parent | d9d908f6e55afd550dd25c5708c8ae396dd26a55 (diff) | |
download | nix-3c992d400af6162c8ac39de11d5750180b857322.zip |
Fix build on Android with recent libc
libc just changed the signedness of sigaction.sa_flags for Android.
https://github.com/rust-lang/libc/commit/841b3eb01644283c3c41ac1d1a2ddcec141f15f2
Diffstat (limited to 'src')
-rw-r--r-- | src/sys/signal.rs | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/src/sys/signal.rs b/src/sys/signal.rs index 73f5f2d4..a49b273f 100644 --- a/src/sys/signal.rs +++ b/src/sys/signal.rs @@ -307,7 +307,6 @@ pub const SIGIOT : Signal = SIGABRT; pub const SIGPOLL : Signal = SIGIO; pub const SIGUNUSED : Signal = SIGSYS; -#[cfg(not(target_os = "android"))] libc_bitflags!{ pub struct SaFlags: libc::c_int { SA_NOCLDSTOP; @@ -320,35 +319,6 @@ libc_bitflags!{ } } -// On 64-bit android, sa_flags is c_uint while on 32-bit android, it is -// c_ulong. -// FIXME: https://github.com/rust-lang/libc/pull/511 -#[cfg(all(target_os = "android", target_pointer_width = "32"))] -libc_bitflags!{ - pub struct SaFlags: libc::c_ulong { - SA_NOCLDSTOP as libc::c_ulong; - SA_NOCLDWAIT as libc::c_ulong; - SA_NODEFER as libc::c_ulong; - SA_ONSTACK as libc::c_ulong; - SA_RESETHAND as libc::c_ulong; - SA_RESTART as libc::c_ulong; - SA_SIGINFO as libc::c_ulong; - } -} - -#[cfg(all(target_os = "android", target_pointer_width = "64"))] -libc_bitflags!{ - pub struct SaFlags: libc::c_uint { - SA_NOCLDSTOP as libc::c_uint; - SA_NOCLDWAIT as libc::c_uint; - SA_NODEFER as libc::c_uint; - SA_ONSTACK as libc::c_uint; - SA_RESETHAND as libc::c_uint; - SA_RESTART as libc::c_uint; - SA_SIGINFO as libc::c_uint; - } -} - libc_enum! { #[repr(i32)] pub enum SigmaskHow { |