//! GENERATED by tools/gen-shim.py from data/syscon-x86_64.json -- do not edit.
//!
//! One block per constant group: the Linux values (what std was compiled
//! with), cosmo's load-time symbols (the host's values), and for tests the
//! Windows and XNU columns of the extracted table.
#![allow(non_upper_case_globals, dead_code, non_snake_case)]
use crate::xlate::{Group, Kind};
// ---- errno (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static E2BIG: i32;
static EACCES: i32;
static EADDRINUSE: i32;
static EADDRNOTAVAIL: i32;
static EAFNOSUPPORT: i32;
static EAGAIN: i32;
static EALREADY: i32;
static EAUTH: i32;
static EBADARCH: i32;
static EBADEXEC: i32;
static EBADF: i32;
static EBADFD: i32;
static EBADMACHO: i32;
static EBADMSG: i32;
static EBADRPC: i32;
static EBUSY: i32;
static ECANCELED: i32;
static ECHILD: i32;
static ECONNABORTED: i32;
static ECONNREFUSED: i32;
static ECONNRESET: i32;
static EDEADLK: i32;
static EDESTADDRREQ: i32;
static EDEVERR: i32;
static EDOM: i32;
static EDQUOT: i32;
static EEXIST: i32;
static EFAULT: i32;
static EFBIG: i32;
static EFTYPE: i32;
static EHOSTDOWN: i32;
static EHOSTUNREACH: i32;
static EIDRM: i32;
static EILSEQ: i32;
static EINPROGRESS: i32;
static EINTR: i32;
static EINVAL: i32;
static EIO: i32;
static EISCONN: i32;
static EISDIR: i32;
static ELOOP: i32;
static EMEDIUMTYPE: i32;
static EMFILE: i32;
static EMLINK: i32;
static EMSGSIZE: i32;
static EMULTIHOP: i32;
static ENAMETOOLONG: i32;
static ENEEDAUTH: i32;
static ENETDOWN: i32;
static ENETRESET: i32;
static ENETUNREACH: i32;
static ENFILE: i32;
static ENOATTR: i32;
static ENOBUFS: i32;
static ENODATA: i32;
static ENODEV: i32;
static ENOENT: i32;
static ENOEXEC: i32;
static ENOLCK: i32;
static ENOLINK: i32;
static ENOMEDIUM: i32;
static ENOMEM: i32;
static ENOMSG: i32;
static ENONET: i32;
static ENOPOLICY: i32;
static ENOPROTOOPT: i32;
static ENOSPC: i32;
static ENOSR: i32;
static ENOSTR: i32;
static ENOSYS: i32;
static ENOTBLK: i32;
static ENOTCONN: i32;
static ENOTDIR: i32;
static ENOTEMPTY: i32;
static ENOTRECOVERABLE: i32;
static ENOTSOCK: i32;
static ENOTSUP: i32;
static ENOTTY: i32;
static ENXIO: i32;
static EOPNOTSUPP: i32;
static EOVERFLOW: i32;
static EOWNERDEAD: i32;
static EPERM: i32;
static EPFNOSUPPORT: i32;
static EPIPE: i32;
static EPROCLIM: i32;
static EPROCUNAVAIL: i32;
static EPROGMISMATCH: i32;
static EPROGUNAVAIL: i32;
static EPROTO: i32;
static EPROTONOSUPPORT: i32;
static EPROTOTYPE: i32;
static EPWROFF: i32;
static ERANGE: i32;
static EREMOTE: i32;
static ERESTART: i32;
static EROFS: i32;
static ERPCMISMATCH: i32;
static ESHLIBVERS: i32;
static ESHUTDOWN: i32;
static ESOCKTNOSUPPORT: i32;
static ESPIPE: i32;
static ESRCH: i32;
static ESTALE: i32;
static ETIME: i32;
static ETIMEDOUT: i32;
static ETOOMANYREFS: i32;
static ETXTBSY: i32;
static EUSERS: i32;
static EXDEV: i32;
}
#[cfg(not(test))]
fn host_errno() -> [i64; 110] { unsafe { [E2BIG as i64, EACCES as i64, EADDRINUSE as i64, EADDRNOTAVAIL as i64, EAFNOSUPPORT as i64, EAGAIN as i64, EALREADY as i64, EAUTH as i64, EBADARCH as i64, EBADEXEC as i64, EBADF as i64, EBADFD as i64, EBADMACHO as i64, EBADMSG as i64, EBADRPC as i64, EBUSY as i64, ECANCELED as i64, ECHILD as i64, ECONNABORTED as i64, ECONNREFUSED as i64, ECONNRESET as i64, EDEADLK as i64, EDESTADDRREQ as i64, EDEVERR as i64, EDOM as i64, EDQUOT as i64, EEXIST as i64, EFAULT as i64, EFBIG as i64, EFTYPE as i64, EHOSTDOWN as i64, EHOSTUNREACH as i64, EIDRM as i64, EILSEQ as i64, EINPROGRESS as i64, EINTR as i64, EINVAL as i64, EIO as i64, EISCONN as i64, EISDIR as i64, ELOOP as i64, EMEDIUMTYPE as i64, EMFILE as i64, EMLINK as i64, EMSGSIZE as i64, EMULTIHOP as i64, ENAMETOOLONG as i64, ENEEDAUTH as i64, ENETDOWN as i64, ENETRESET as i64, ENETUNREACH as i64, ENFILE as i64, ENOATTR as i64, ENOBUFS as i64, ENODATA as i64, ENODEV as i64, ENOENT as i64, ENOEXEC as i64, ENOLCK as i64, ENOLINK as i64, ENOMEDIUM as i64, ENOMEM as i64, ENOMSG as i64, ENONET as i64, ENOPOLICY as i64, ENOPROTOOPT as i64, ENOSPC as i64, ENOSR as i64, ENOSTR as i64, ENOSYS as i64, ENOTBLK as i64, ENOTCONN as i64, ENOTDIR as i64, ENOTEMPTY as i64, ENOTRECOVERABLE as i64, ENOTSOCK as i64, ENOTSUP as i64, ENOTTY as i64, ENXIO as i64, EOPNOTSUPP as i64, EOVERFLOW as i64, EOWNERDEAD as i64, EPERM as i64, EPFNOSUPPORT as i64, EPIPE as i64, EPROCLIM as i64, EPROCUNAVAIL as i64, EPROGMISMATCH as i64, EPROGUNAVAIL as i64, EPROTO as i64, EPROTONOSUPPORT as i64, EPROTOTYPE as i64, EPWROFF as i64, ERANGE as i64, EREMOTE as i64, ERESTART as i64, EROFS as i64, ERPCMISMATCH as i64, ESHLIBVERS as i64, ESHUTDOWN as i64, ESOCKTNOSUPPORT as i64, ESPIPE as i64, ESRCH as i64, ESTALE as i64, ETIME as i64, ETIMEDOUT as i64, ETOOMANYREFS as i64, ETXTBSY as i64, EUSERS as i64, EXDEV as i64] } }
#[cfg(test)]
fn host_errno() -> [i64; 110] { crate::xlate::test_host(&WINDOWS_errno, &XNU_errno) }
pub static NAMES_errno: [&str; 110] = ["E2BIG", "EACCES", "EADDRINUSE", "EADDRNOTAVAIL", "EAFNOSUPPORT", "EAGAIN", "EALREADY", "EAUTH", "EBADARCH", "EBADEXEC", "EBADF", "EBADFD", "EBADMACHO", "EBADMSG", "EBADRPC", "EBUSY", "ECANCELED", "ECHILD", "ECONNABORTED", "ECONNREFUSED", "ECONNRESET", "EDEADLK", "EDESTADDRREQ", "EDEVERR", "EDOM", "EDQUOT", "EEXIST", "EFAULT", "EFBIG", "EFTYPE", "EHOSTDOWN", "EHOSTUNREACH", "EIDRM", "EILSEQ", "EINPROGRESS", "EINTR", "EINVAL", "EIO", "EISCONN", "EISDIR", "ELOOP", "EMEDIUMTYPE", "EMFILE", "EMLINK", "EMSGSIZE", "EMULTIHOP", "ENAMETOOLONG", "ENEEDAUTH", "ENETDOWN", "ENETRESET", "ENETUNREACH", "ENFILE", "ENOATTR", "ENOBUFS", "ENODATA", "ENODEV", "ENOENT", "ENOEXEC", "ENOLCK", "ENOLINK", "ENOMEDIUM", "ENOMEM", "ENOMSG", "ENONET", "ENOPOLICY", "ENOPROTOOPT", "ENOSPC", "ENOSR", "ENOSTR", "ENOSYS", "ENOTBLK", "ENOTCONN", "ENOTDIR", "ENOTEMPTY", "ENOTRECOVERABLE", "ENOTSOCK", "ENOTSUP", "ENOTTY", "ENXIO", "EOPNOTSUPP", "EOVERFLOW", "EOWNERDEAD", "EPERM", "EPFNOSUPPORT", "EPIPE", "EPROCLIM", "EPROCUNAVAIL", "EPROGMISMATCH", "EPROGUNAVAIL", "EPROTO", "EPROTONOSUPPORT", "EPROTOTYPE", "EPWROFF", "ERANGE", "EREMOTE", "ERESTART", "EROFS", "ERPCMISMATCH", "ESHLIBVERS", "ESHUTDOWN", "ESOCKTNOSUPPORT", "ESPIPE", "ESRCH", "ESTALE", "ETIME", "ETIMEDOUT", "ETOOMANYREFS", "ETXTBSY", "EUSERS", "EXDEV"];
pub static LINUX_errno: [i64; 110] = [7, 13, 98, 99, 97, 11, 114, 306, 313, 312, 9, 77, 315, 74, 300, 16, 125, 10, 103, 111, 104, 35, 89, 311, 33, 122, 17, 14, 27, 305, 112, 113, 43, 84, 115, 4, 22, 5, 106, 21, 40, 124, 24, 31, 90, 72, 36, 307, 100, 102, 101, 23, 309, 105, 61, 19, 2, 8, 37, 67, 123, 12, 42, 64, 316, 92, 28, 63, 60, 38, 15, 107, 20, 39, 131, 88, 95, 25, 6, 95, 75, 130, 1, 96, 32, 308, 304, 303, 302, 71, 93, 91, 310, 34, 66, 85, 30, 301, 314, 108, 94, 29, 3, 116, 62, 110, 109, 26, 87, 18];
pub static WINDOWS_errno: [i64; 110] = [1639, 5, 10048, 10049, 10047, 10035, 10037, 1244, 216, 192, 6, 0, 0, 0, 1626, 170, 1223, 128, 10053, 10061, 10054, 1131, 10039, 483, 20000, 1816, 183, 487, 223, 222, 10064, 10065, 1287, 582, 10036, 10004, 87, 1117, 10056, 267, 1921, 0, 4, 1142, 10040, 0, 10063, 224, 10050, 10052, 10051, 331, 117, 10055, 232, 1200, 2, 193, 158, 0, 0, 14, 4306, 0, 0, 10042, 39, 0, 0, 1, 26, 10057, 3, 145, 0, 10038, 10045, 1118, 1112, 10045, 534, 105, 12, 10046, 109, 10067, 15841, 595, 329, 7065, 10043, 10041, 639, 6604, 10071, 20000, 6009, 1627, 0, 10058, 10044, 25, 566, 10070, 1460, 1460, 10059, 148, 10068, 17];
pub static XNU_errno: [i64; 110] = [7, 13, 48, 49, 47, 35, 37, 80, 86, 85, 9, 9, 88, 94, 72, 16, 89, 10, 53, 61, 54, 11, 39, 83, 33, 69, 17, 14, 27, 79, 64, 65, 90, 92, 36, 4, 22, 5, 56, 21, 62, 0, 24, 31, 40, 95, 63, 81, 50, 52, 51, 23, 93, 55, 96, 19, 2, 8, 77, 97, 0, 12, 91, 317, 103, 42, 28, 98, 99, 78, 15, 57, 20, 66, 104, 38, 45, 25, 6, 102, 84, 105, 1, 46, 32, 67, 76, 75, 74, 100, 43, 41, 82, 34, 71, 318, 30, 73, 87, 58, 44, 29, 3, 70, 101, 60, 59, 26, 68, 18];
static mut HOST_errno: [i64; 110] = [0; 110];
static STATE_errno: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn errno() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_errno, &LINUX_errno, &STATE_errno, &raw mut HOST_errno, host_errno)
}
// ---- compat (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static EWOULDBLOCK: i32;
static MAP_32BIT: i32;
static MAP_ANON: i32;
static MAP_DENYWRITE: i32;
static MAP_EXECUTABLE: i32;
static MAP_NOCORE: i32;
static O_LARGEFILE: u32;
static RLIMIT_VMEM: u32;
static SA_NOMASK: u64;
static SA_ONESHOT: u64;
static SIGIOT: i32;
static SIGPOLL: i32;
}
#[cfg(not(test))]
fn host_compat() -> [i64; 12] { unsafe { [EWOULDBLOCK as i64, MAP_32BIT as i64, MAP_ANON as i64, MAP_DENYWRITE as i64, MAP_EXECUTABLE as i64, MAP_NOCORE as i64, O_LARGEFILE as i64, RLIMIT_VMEM as i64, SA_NOMASK as i64, SA_ONESHOT as i64, SIGIOT as i64, SIGPOLL as i64] } }
#[cfg(test)]
fn host_compat() -> [i64; 12] { crate::xlate::test_host(&WINDOWS_compat, &XNU_compat) }
pub static NAMES_compat: [&str; 12] = ["EWOULDBLOCK", "MAP_32BIT", "MAP_ANON", "MAP_DENYWRITE", "MAP_EXECUTABLE", "MAP_NOCORE", "O_LARGEFILE", "RLIMIT_VMEM", "SA_NOMASK", "SA_ONESHOT", "SIGIOT", "SIGPOLL"];
pub static LINUX_compat: [i64; 12] = [11, 64, 32, 2048, 4096, 0, 32768, 9, 1073741824, 2147483648, 6, 29];
pub static WINDOWS_compat: [i64; 12] = [10035, 0, 32, 0, 0, 0, 0, 127, 1073741824, 2147483648, 6, 29];
pub static XNU_compat: [i64; 12] = [35, 0, 4096, 0, 0, 0, 0, 5, 16, 4, 6, 23];
static mut HOST_compat: [i64; 12] = [0; 12];
static STATE_compat: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn compat() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_compat, &LINUX_compat, &STATE_compat, &raw mut HOST_compat, host_compat)
}
// ---- junkerr (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static EADV: i32;
static EBADE: i32;
static EBADR: i32;
static EBADRQC: i32;
static EBADSLT: i32;
static ECHRNG: i32;
static ECOMM: i32;
static EDOTDOT: i32;
static EHWPOISON: i32;
static EISNAM: i32;
static EKEYEXPIRED: i32;
static EKEYREJECTED: i32;
static EKEYREVOKED: i32;
static EL2HLT: i32;
static EL2NSYNC: i32;
static EL3HLT: i32;
static EL3RST: i32;
static ELIBACC: i32;
static ELIBBAD: i32;
static ELIBEXEC: i32;
static ELIBMAX: i32;
static ELIBSCN: i32;
static ELNRNG: i32;
static ENAVAIL: i32;
static ENOANO: i32;
static ENOCSI: i32;
static ENOKEY: i32;
static ENOPKG: i32;
static ENOTNAM: i32;
static ENOTUNIQ: i32;
static EREMCHG: i32;
static EREMOTEIO: i32;
static ERFKILL: i32;
static ESRMNT: i32;
static ESTRPIPE: i32;
static EUCLEAN: i32;
static EUNATCH: i32;
static EXFULL: i32;
}
#[cfg(not(test))]
fn host_junkerr() -> [i64; 38] { unsafe { [EADV as i64, EBADE as i64, EBADR as i64, EBADRQC as i64, EBADSLT as i64, ECHRNG as i64, ECOMM as i64, EDOTDOT as i64, EHWPOISON as i64, EISNAM as i64, EKEYEXPIRED as i64, EKEYREJECTED as i64, EKEYREVOKED as i64, EL2HLT as i64, EL2NSYNC as i64, EL3HLT as i64, EL3RST as i64, ELIBACC as i64, ELIBBAD as i64, ELIBEXEC as i64, ELIBMAX as i64, ELIBSCN as i64, ELNRNG as i64, ENAVAIL as i64, ENOANO as i64, ENOCSI as i64, ENOKEY as i64, ENOPKG as i64, ENOTNAM as i64, ENOTUNIQ as i64, EREMCHG as i64, EREMOTEIO as i64, ERFKILL as i64, ESRMNT as i64, ESTRPIPE as i64, EUCLEAN as i64, EUNATCH as i64, EXFULL as i64] } }
#[cfg(test)]
fn host_junkerr() -> [i64; 38] { crate::xlate::test_host(&WINDOWS_junkerr, &XNU_junkerr) }
pub static NAMES_junkerr: [&str; 38] = ["EADV", "EBADE", "EBADR", "EBADRQC", "EBADSLT", "ECHRNG", "ECOMM", "EDOTDOT", "EHWPOISON", "EISNAM", "EKEYEXPIRED", "EKEYREJECTED", "EKEYREVOKED", "EL2HLT", "EL2NSYNC", "EL3HLT", "EL3RST", "ELIBACC", "ELIBBAD", "ELIBEXEC", "ELIBMAX", "ELIBSCN", "ELNRNG", "ENAVAIL", "ENOANO", "ENOCSI", "ENOKEY", "ENOPKG", "ENOTNAM", "ENOTUNIQ", "EREMCHG", "EREMOTEIO", "ERFKILL", "ESRMNT", "ESTRPIPE", "EUCLEAN", "EUNATCH", "EXFULL"];
pub static LINUX_junkerr: [i64; 38] = [68, 52, 53, 56, 57, 44, 70, 73, 133, 120, 127, 129, 128, 51, 45, 46, 47, 79, 80, 83, 82, 81, 48, 119, 55, 50, 126, 65, 118, 76, 78, 121, 132, 69, 86, 117, 49, 54];
pub static WINDOWS_junkerr: [i64; 38] = [-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1];
pub static XNU_junkerr: [i64; 38] = [-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1];
static mut HOST_junkerr: [i64; 38] = [0; 38];
static STATE_junkerr: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn junkerr() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_junkerr, &LINUX_junkerr, &STATE_junkerr, &raw mut HOST_junkerr, host_junkerr)
}
// ---- open (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static O_APPEND: u32;
static O_ASYNC: u32;
static O_CLOEXEC: u32;
static O_COMPRESSED: u32;
static O_CREAT: u32;
static O_DIRECT: u32;
static O_DIRECTORY: u32;
static O_DSYNC: u32;
static O_EXCL: u32;
static O_EXEC: u32;
static O_EXLOCK: u32;
static O_INDEXED: u32;
static O_NOATIME: u32;
static O_NOCTTY: u32;
static O_NOFOLLOW: u32;
static O_NOFOLLOW_ANY: u32;
static O_NONBLOCK: u32;
static O_PATH: u32;
static O_RANDOM: u32;
static O_RSYNC: u32;
static O_SEARCH: u32;
static O_SEQUENTIAL: u32;
static O_SHLOCK: u32;
static O_SYNC: u32;
static O_TMPFILE: u32;
static O_TRUNC: u32;
static O_TTY_INIT: u32;
static O_UNLINK: u32;
static O_VERIFY: u32;
}
#[cfg(not(test))]
fn host_open() -> [i64; 29] { unsafe { [O_APPEND as i64, O_ASYNC as i64, O_CLOEXEC as i64, O_COMPRESSED as i64, O_CREAT as i64, O_DIRECT as i64, O_DIRECTORY as i64, O_DSYNC as i64, O_EXCL as i64, O_EXEC as i64, O_EXLOCK as i64, O_INDEXED as i64, O_NOATIME as i64, O_NOCTTY as i64, O_NOFOLLOW as i64, O_NOFOLLOW_ANY as i64, O_NONBLOCK as i64, O_PATH as i64, O_RANDOM as i64, O_RSYNC as i64, O_SEARCH as i64, O_SEQUENTIAL as i64, O_SHLOCK as i64, O_SYNC as i64, O_TMPFILE as i64, O_TRUNC as i64, O_TTY_INIT as i64, O_UNLINK as i64, O_VERIFY as i64] } }
#[cfg(test)]
fn host_open() -> [i64; 29] { crate::xlate::test_host(&WINDOWS_open, &XNU_open) }
pub static NAMES_open: [&str; 29] = ["O_APPEND", "O_ASYNC", "O_CLOEXEC", "O_COMPRESSED", "O_CREAT", "O_DIRECT", "O_DIRECTORY", "O_DSYNC", "O_EXCL", "O_EXEC", "O_EXLOCK", "O_INDEXED", "O_NOATIME", "O_NOCTTY", "O_NOFOLLOW", "O_NOFOLLOW_ANY", "O_NONBLOCK", "O_PATH", "O_RANDOM", "O_RSYNC", "O_SEARCH", "O_SEQUENTIAL", "O_SHLOCK", "O_SYNC", "O_TMPFILE", "O_TRUNC", "O_TTY_INIT", "O_UNLINK", "O_VERIFY"];
pub static LINUX_open: [i64; 29] = [1024, 8192, 524288, 0, 64, 16384, 65536, 4096, 128, 2097152, 4294967295, 0, 262144, 256, 131072, 4294967295, 2048, 2097152, 0, 1052672, 4294967295, 0, 4294967295, 1052672, 4259840, 512, 0, 1073741824, 4294967295];
pub static WINDOWS_open: [i64; 29] = [1024, 4294967295, 524288, 536870912, 64, 16384, 65536, 4294967295, 128, 0, 4294967295, 268435456, 0, 0, 131072, 4294967295, 2048, 4294967295, 2147483648, 4294967295, 4294967295, 1073741824, 4294967295, 4294967295, 4294967295, 512, 0, 67109120, 4294967295];
pub static XNU_open: [i64; 29] = [8, 64, 16777216, 0, 512, 4294967295, 1048576, 4194304, 2048, 0, 32, 0, 0, 131072, 256, 536870912, 4, 4294967295, 0, 4294967295, 4294967295, 0, 16, 128, 4294967295, 1024, 0, 1073741824, 4294967295];
static mut HOST_open: [i64; 29] = [0; 29];
static STATE_open: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn open() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_open, &LINUX_open, &STATE_open, &raw mut HOST_open, host_open)
}
// ---- mmap (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static MAP_ANONYMOUS: i32;
static MAP_CONCEAL: i32;
static MAP_FILE: i32;
static MAP_FIXED: i32;
static MAP_FIXED_NOREPLACE: i32;
static MAP_HASSEMAPHORE: i32;
static MAP_HUGETLB: i32;
static MAP_INHERIT: i32;
static MAP_JIT: i32;
static MAP_LOCKED: i32;
static MAP_NOCACHE: i32;
static MAP_NOEXTEND: i32;
static MAP_NONBLOCK: i32;
static MAP_NORESERVE: i32;
static MAP_NOSYNC: i32;
static MAP_POPULATE: i32;
static MAP_PRIVATE: i32;
static MAP_SHARED: i32;
static MAP_SHARED_VALIDATE: i32;
static MAP_SYNC: i32;
static MAP_TYPE: i32;
}
#[cfg(not(test))]
fn host_mmap() -> [i64; 21] { unsafe { [MAP_ANONYMOUS as i64, MAP_CONCEAL as i64, MAP_FILE as i64, MAP_FIXED as i64, MAP_FIXED_NOREPLACE as i64, MAP_HASSEMAPHORE as i64, MAP_HUGETLB as i64, MAP_INHERIT as i64, MAP_JIT as i64, MAP_LOCKED as i64, MAP_NOCACHE as i64, MAP_NOEXTEND as i64, MAP_NONBLOCK as i64, MAP_NORESERVE as i64, MAP_NOSYNC as i64, MAP_POPULATE as i64, MAP_PRIVATE as i64, MAP_SHARED as i64, MAP_SHARED_VALIDATE as i64, MAP_SYNC as i64, MAP_TYPE as i64] } }
#[cfg(test)]
fn host_mmap() -> [i64; 21] { crate::xlate::test_host(&WINDOWS_mmap, &XNU_mmap) }
pub static NAMES_mmap: [&str; 21] = ["MAP_ANONYMOUS", "MAP_CONCEAL", "MAP_FILE", "MAP_FIXED", "MAP_FIXED_NOREPLACE", "MAP_HASSEMAPHORE", "MAP_HUGETLB", "MAP_INHERIT", "MAP_JIT", "MAP_LOCKED", "MAP_NOCACHE", "MAP_NOEXTEND", "MAP_NONBLOCK", "MAP_NORESERVE", "MAP_NOSYNC", "MAP_POPULATE", "MAP_PRIVATE", "MAP_SHARED", "MAP_SHARED_VALIDATE", "MAP_SYNC", "MAP_TYPE"];
pub static LINUX_mmap: [i64; 21] = [32, 0, 0, 16, 134217728, 0, 262144, -1, 0, 8192, 0, 0, 65536, 16384, 0, 32768, 2, 1, 3, 524288, 15];
pub static WINDOWS_mmap: [i64; 21] = [32, 0, 0, 16, 134217728, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 2, 1, 1, 0, 15];
pub static XNU_mmap: [i64; 21] = [4096, 0, 0, 16, 16384, 512, -1, -1, 0, 0, 1024, 256, 0, 64, 0, 0, 2, 1, 1, 0, 15];
static mut HOST_mmap: [i64; 21] = [0; 21];
static STATE_mmap: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn mmap() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_mmap, &LINUX_mmap, &STATE_mmap, &raw mut HOST_mmap, host_mmap)
}
// ---- mprot (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static PROT_EXEC: i32;
static PROT_GUARD: i32;
static PROT_NONE: i32;
static PROT_READ: i32;
static PROT_WRITE: i32;
}
#[cfg(not(test))]
fn host_mprot() -> [i64; 5] { unsafe { [PROT_EXEC as i64, PROT_GUARD as i64, PROT_NONE as i64, PROT_READ as i64, PROT_WRITE as i64] } }
#[cfg(test)]
fn host_mprot() -> [i64; 5] { crate::xlate::test_host(&WINDOWS_mprot, &XNU_mprot) }
pub static NAMES_mprot: [&str; 5] = ["PROT_EXEC", "PROT_GUARD", "PROT_NONE", "PROT_READ", "PROT_WRITE"];
pub static LINUX_mprot: [i64; 5] = [4, 0, 0, 1, 2];
pub static WINDOWS_mprot: [i64; 5] = [4, 256, 0, 1, 2];
pub static XNU_mprot: [i64; 5] = [4, 0, 0, 1, 2];
static mut HOST_mprot: [i64; 5] = [0; 5];
static STATE_mprot: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn mprot() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_mprot, &LINUX_mprot, &STATE_mprot, &raw mut HOST_mprot, host_mprot)
}
// ---- msg (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static MSG_CTRUNC: i32;
static MSG_DONTROUTE: i32;
static MSG_DONTWAIT: i32;
static MSG_FASTOPEN: i32;
static MSG_NOSIGNAL: i32;
static MSG_OOB: i32;
static MSG_PEEK: i32;
static MSG_TRUNC: i32;
static MSG_WAITALL: i32;
}
#[cfg(not(test))]
fn host_msg() -> [i64; 9] { unsafe { [MSG_CTRUNC as i64, MSG_DONTROUTE as i64, MSG_DONTWAIT as i64, MSG_FASTOPEN as i64, MSG_NOSIGNAL as i64, MSG_OOB as i64, MSG_PEEK as i64, MSG_TRUNC as i64, MSG_WAITALL as i64] } }
#[cfg(test)]
fn host_msg() -> [i64; 9] { crate::xlate::test_host(&WINDOWS_msg, &XNU_msg) }
pub static NAMES_msg: [&str; 9] = ["MSG_CTRUNC", "MSG_DONTROUTE", "MSG_DONTWAIT", "MSG_FASTOPEN", "MSG_NOSIGNAL", "MSG_OOB", "MSG_PEEK", "MSG_TRUNC", "MSG_WAITALL"];
pub static LINUX_msg: [i64; 9] = [8, 4, 64, 536870912, 16384, 1, 2, 32, 256];
pub static WINDOWS_msg: [i64; 9] = [512, 4, 64, -1, 268435456, 1, 2, 256, 8];
pub static XNU_msg: [i64; 9] = [32, 4, 128, -1, 524288, 1, 2, 16, 64];
static mut HOST_msg: [i64; 9] = [0; 9];
static STATE_msg: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn msg() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_msg, &LINUX_msg, &STATE_msg, &raw mut HOST_msg, host_msg)
}
// ---- poll (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static POLLERR: i16;
static POLLHUP: i16;
static POLLIN: i16;
static POLLNVAL: i16;
static POLLOUT: i16;
static POLLPRI: i16;
static POLLRDBAND: i16;
static POLLRDHUP: i16;
static POLLRDNORM: i16;
static POLLWRBAND: i16;
static POLLWRNORM: i16;
}
#[cfg(not(test))]
fn host_poll() -> [i64; 11] { unsafe { [POLLERR as i64, POLLHUP as i64, POLLIN as i64, POLLNVAL as i64, POLLOUT as i64, POLLPRI as i64, POLLRDBAND as i64, POLLRDHUP as i64, POLLRDNORM as i64, POLLWRBAND as i64, POLLWRNORM as i64] } }
#[cfg(test)]
fn host_poll() -> [i64; 11] { crate::xlate::test_host(&WINDOWS_poll, &XNU_poll) }
pub static NAMES_poll: [&str; 11] = ["POLLERR", "POLLHUP", "POLLIN", "POLLNVAL", "POLLOUT", "POLLPRI", "POLLRDBAND", "POLLRDHUP", "POLLRDNORM", "POLLWRBAND", "POLLWRNORM"];
pub static LINUX_poll: [i64; 11] = [8, 16, 1, 32, 4, 2, 128, 8192, 64, 512, 256];
pub static WINDOWS_poll: [i64; 11] = [1, 2, 768, 4, 16, 1024, 512, 2, 256, 32, 16];
pub static XNU_poll: [i64; 11] = [8, 16, 1, 32, 4, 2, 128, 16, 64, 256, 4];
static mut HOST_poll: [i64; 11] = [0; 11];
static STATE_poll: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn poll() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_poll, &LINUX_poll, &STATE_poll, &raw mut HOST_poll, host_poll)
}
// ---- sock (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static SOCK_CLOEXEC: i32;
static SOCK_DCCP: i32;
static SOCK_DGRAM: i32;
static SOCK_NONBLOCK: i32;
static SOCK_PACKET: i32;
static SOCK_RAW: i32;
static SOCK_RDM: i32;
static SOCK_SEQPACKET: i32;
static SOCK_STREAM: i32;
}
#[cfg(not(test))]
fn host_sock() -> [i64; 9] { unsafe { [SOCK_CLOEXEC as i64, SOCK_DCCP as i64, SOCK_DGRAM as i64, SOCK_NONBLOCK as i64, SOCK_PACKET as i64, SOCK_RAW as i64, SOCK_RDM as i64, SOCK_SEQPACKET as i64, SOCK_STREAM as i64] } }
#[cfg(test)]
fn host_sock() -> [i64; 9] { crate::xlate::test_host(&WINDOWS_sock, &XNU_sock) }
pub static NAMES_sock: [&str; 9] = ["SOCK_CLOEXEC", "SOCK_DCCP", "SOCK_DGRAM", "SOCK_NONBLOCK", "SOCK_PACKET", "SOCK_RAW", "SOCK_RDM", "SOCK_SEQPACKET", "SOCK_STREAM"];
pub static LINUX_sock: [i64; 9] = [524288, 6, 2, 2048, 10, 3, 4, 5, 1];
pub static WINDOWS_sock: [i64; 9] = [524288, 0, 2, 2048, 0, 3, 4, 5, 1];
pub static XNU_sock: [i64; 9] = [524288, 0, 2, 2048, 0, 3, 4, 5, 1];
static mut HOST_sock: [i64; 9] = [0; 9];
static STATE_sock: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn sock() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_sock, &LINUX_sock, &STATE_sock, &raw mut HOST_sock, host_sock)
}
// ---- sigact (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static SA_NOCLDSTOP: u64;
static SA_NOCLDWAIT: u64;
static SA_NODEFER: u64;
static SA_ONSTACK: u64;
static SA_RESETHAND: u64;
static SA_RESTART: u64;
static SA_SIGINFO: u64;
}
#[cfg(not(test))]
fn host_sigact() -> [i64; 7] { unsafe { [SA_NOCLDSTOP as i64, SA_NOCLDWAIT as i64, SA_NODEFER as i64, SA_ONSTACK as i64, SA_RESETHAND as i64, SA_RESTART as i64, SA_SIGINFO as i64] } }
#[cfg(test)]
fn host_sigact() -> [i64; 7] { crate::xlate::test_host(&WINDOWS_sigact, &XNU_sigact) }
pub static NAMES_sigact: [&str; 7] = ["SA_NOCLDSTOP", "SA_NOCLDWAIT", "SA_NODEFER", "SA_ONSTACK", "SA_RESETHAND", "SA_RESTART", "SA_SIGINFO"];
pub static LINUX_sigact: [i64; 7] = [1, 2, 1073741824, 134217728, 2147483648, 268435456, 4];
pub static WINDOWS_sigact: [i64; 7] = [1, 2, 1073741824, 134217728, 2147483648, 268435456, 4];
pub static XNU_sigact: [i64; 7] = [8, 32, 16, 1, 4, 2, 64];
static mut HOST_sigact: [i64; 7] = [0; 7];
static STATE_sigact: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn sigact() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_sigact, &LINUX_sigact, &STATE_sigact, &raw mut HOST_sigact, host_sigact)
}
// ---- waitpid (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static WCONTINUED: i32;
static WNOHANG: i32;
static WUNTRACED: i32;
}
#[cfg(not(test))]
fn host_waitpid() -> [i64; 3] { unsafe { [WCONTINUED as i64, WNOHANG as i64, WUNTRACED as i64] } }
#[cfg(test)]
fn host_waitpid() -> [i64; 3] { crate::xlate::test_host(&WINDOWS_waitpid, &XNU_waitpid) }
pub static NAMES_waitpid: [&str; 3] = ["WCONTINUED", "WNOHANG", "WUNTRACED"];
pub static LINUX_waitpid: [i64; 3] = [8, 1, 2];
pub static WINDOWS_waitpid: [i64; 3] = [0, 1, 0];
pub static XNU_waitpid: [i64; 3] = [16, 1, 2];
static mut HOST_waitpid: [i64; 3] = [0; 3];
static STATE_waitpid: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn waitpid() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_waitpid, &LINUX_waitpid, &STATE_waitpid, &raw mut HOST_waitpid, host_waitpid)
}
// ---- waitid (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static WEXITED: i32;
static WNOWAIT: i32;
static WSTOPPED: i32;
}
#[cfg(not(test))]
fn host_waitid() -> [i64; 3] { unsafe { [WEXITED as i64, WNOWAIT as i64, WSTOPPED as i64] } }
#[cfg(test)]
fn host_waitid() -> [i64; 3] { crate::xlate::test_host(&WINDOWS_waitid, &XNU_waitid) }
pub static NAMES_waitid: [&str; 3] = ["WEXITED", "WNOWAIT", "WSTOPPED"];
pub static LINUX_waitid: [i64; 3] = [4, 16777216, 2];
pub static WINDOWS_waitid: [i64; 3] = [0, 0, 0];
pub static XNU_waitid: [i64; 3] = [4, 32, 8];
static mut HOST_waitid: [i64; 3] = [0; 3];
static STATE_waitid: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn waitid() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_waitid, &LINUX_waitid, &STATE_waitid, &raw mut HOST_waitid, host_waitid)
}
// ---- at (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static AT_EACCESS: i32;
static AT_EMPTY_PATH: i32;
static AT_FDCWD: i32;
static AT_REMOVEDIR: i32;
static AT_SYMLINK_FOLLOW: i32;
static AT_SYMLINK_NOFOLLOW: i32;
}
#[cfg(not(test))]
fn host_at() -> [i64; 6] { unsafe { [AT_EACCESS as i64, AT_EMPTY_PATH as i64, AT_FDCWD as i64, AT_REMOVEDIR as i64, AT_SYMLINK_FOLLOW as i64, AT_SYMLINK_NOFOLLOW as i64] } }
#[cfg(test)]
fn host_at() -> [i64; 6] { crate::xlate::test_host(&WINDOWS_at, &XNU_at) }
pub static NAMES_at: [&str; 6] = ["AT_EACCESS", "AT_EMPTY_PATH", "AT_FDCWD", "AT_REMOVEDIR", "AT_SYMLINK_FOLLOW", "AT_SYMLINK_NOFOLLOW"];
pub static LINUX_at: [i64; 6] = [512, 4096, -100, 512, 1024, 256];
pub static WINDOWS_at: [i64; 6] = [0, 4096, -100, 512, 1024, 256];
pub static XNU_at: [i64; 6] = [16, 0, -2, 128, 64, 32];
static mut HOST_at: [i64; 6] = [0; 6];
static STATE_at: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn at() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_at, &LINUX_at, &STATE_at, &raw mut HOST_at, host_at)
}
// ---- af (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static AF_ALG: i32;
static AF_APPLETALK: i32;
static AF_ASH: i32;
static AF_ATMPVC: i32;
static AF_ATMSVC: i32;
static AF_AX25: i32;
static AF_BLUETOOTH: i32;
static AF_BRIDGE: i32;
static AF_CAIF: i32;
static AF_CAN: i32;
static AF_ECONET: i32;
static AF_FILE: i32;
static AF_IB: i32;
static AF_IEEE802154: i32;
static AF_INET: i32;
static AF_INET6: i32;
static AF_IPX: i32;
static AF_IRDA: i32;
static AF_ISDN: i32;
static AF_IUCV: i32;
static AF_KCM: i32;
static AF_KEY: i32;
static AF_LINK: i32;
static AF_LLC: i32;
static AF_LOCAL: i32;
static AF_MAX: i32;
static AF_MPLS: i32;
static AF_NETBEUI: i32;
static AF_NETLINK: i32;
static AF_NETROM: i32;
static AF_NFC: i32;
static AF_PACKET: i32;
static AF_PHONET: i32;
static AF_PPPOX: i32;
static AF_RDS: i32;
static AF_ROSE: i32;
static AF_ROUTE: i32;
static AF_RXRPC: i32;
static AF_SECURITY: i32;
static AF_SNA: i32;
static AF_TIPC: i32;
static AF_UNIX: i32;
static AF_UNSPEC: i32;
static AF_VSOCK: i32;
static AF_WANPIPE: i32;
static AF_X25: i32;
static PF_CAN: i32;
}
#[cfg(not(test))]
fn host_af() -> [i64; 47] { unsafe { [AF_ALG as i64, AF_APPLETALK as i64, AF_ASH as i64, AF_ATMPVC as i64, AF_ATMSVC as i64, AF_AX25 as i64, AF_BLUETOOTH as i64, AF_BRIDGE as i64, AF_CAIF as i64, AF_CAN as i64, AF_ECONET as i64, AF_FILE as i64, AF_IB as i64, AF_IEEE802154 as i64, AF_INET as i64, AF_INET6 as i64, AF_IPX as i64, AF_IRDA as i64, AF_ISDN as i64, AF_IUCV as i64, AF_KCM as i64, AF_KEY as i64, AF_LINK as i64, AF_LLC as i64, AF_LOCAL as i64, AF_MAX as i64, AF_MPLS as i64, AF_NETBEUI as i64, AF_NETLINK as i64, AF_NETROM as i64, AF_NFC as i64, AF_PACKET as i64, AF_PHONET as i64, AF_PPPOX as i64, AF_RDS as i64, AF_ROSE as i64, AF_ROUTE as i64, AF_RXRPC as i64, AF_SECURITY as i64, AF_SNA as i64, AF_TIPC as i64, AF_UNIX as i64, AF_UNSPEC as i64, AF_VSOCK as i64, AF_WANPIPE as i64, AF_X25 as i64, PF_CAN as i64] } }
#[cfg(test)]
fn host_af() -> [i64; 47] { crate::xlate::test_host(&WINDOWS_af, &XNU_af) }
pub static NAMES_af: [&str; 47] = ["AF_ALG", "AF_APPLETALK", "AF_ASH", "AF_ATMPVC", "AF_ATMSVC", "AF_AX25", "AF_BLUETOOTH", "AF_BRIDGE", "AF_CAIF", "AF_CAN", "AF_ECONET", "AF_FILE", "AF_IB", "AF_IEEE802154", "AF_INET", "AF_INET6", "AF_IPX", "AF_IRDA", "AF_ISDN", "AF_IUCV", "AF_KCM", "AF_KEY", "AF_LINK", "AF_LLC", "AF_LOCAL", "AF_MAX", "AF_MPLS", "AF_NETBEUI", "AF_NETLINK", "AF_NETROM", "AF_NFC", "AF_PACKET", "AF_PHONET", "AF_PPPOX", "AF_RDS", "AF_ROSE", "AF_ROUTE", "AF_RXRPC", "AF_SECURITY", "AF_SNA", "AF_TIPC", "AF_UNIX", "AF_UNSPEC", "AF_VSOCK", "AF_WANPIPE", "AF_X25", "PF_CAN"];
pub static LINUX_af: [i64; 47] = [38, 5, 18, 8, 20, 3, 31, 7, 37, 29, 19, 1, 27, 36, 2, 10, 4, 23, 34, 32, 41, 15, -1, 26, 1, 42, 28, 13, 16, 6, 39, 17, 35, 24, 21, 11, 16, 33, 14, 22, 30, 1, 0, 40, 25, 9, 29];
pub static WINDOWS_af: [i64; 47] = [-1, 16, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 2, 23, 6, -1, -1, -1, -1, -1, -1, -1, 1, 35, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 11, -1, 1, 0, -1, -1, -1, 0];
pub static XNU_af: [i64; 47] = [-1, 16, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 2, 30, 23, -1, 28, -1, -1, -1, 18, -1, 1, 40, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 17, -1, -1, 11, -1, 1, 0, -1, -1, -1, 0];
static mut HOST_af: [i64; 47] = [0; 47];
static STATE_af: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn af() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_af, &LINUX_af, &STATE_af, &raw mut HOST_af, host_af)
}
// ---- pf (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static PF_ALG: i32;
static PF_APPLETALK: i32;
static PF_ASH: i32;
static PF_ATMPVC: i32;
static PF_ATMSVC: i32;
static PF_AX25: i32;
static PF_BLUETOOTH: i32;
static PF_BRIDGE: i32;
static PF_CAIF: i32;
static PF_ECONET: i32;
static PF_FILE: i32;
static PF_IB: i32;
static PF_IEEE802154: i32;
static PF_INET: i32;
static PF_INET6: i32;
static PF_IPX: i32;
static PF_IRDA: i32;
static PF_ISDN: i32;
static PF_IUCV: i32;
static PF_KCM: i32;
static PF_KEY: i32;
static PF_LLC: i32;
static PF_LOCAL: i32;
static PF_MAX: i32;
static PF_MPLS: i32;
static PF_NETBEUI: i32;
static PF_NETLINK: i32;
static PF_NETROM: i32;
static PF_NFC: i32;
static PF_PACKET: i32;
static PF_PHONET: i32;
static PF_PPPOX: i32;
static PF_RDS: i32;
static PF_ROSE: i32;
static PF_ROUTE: i32;
static PF_RXRPC: i32;
static PF_SECURITY: i32;
static PF_SNA: i32;
static PF_TIPC: i32;
static PF_UNIX: i32;
static PF_UNSPEC: i32;
static PF_VSOCK: i32;
static PF_WANPIPE: i32;
static PF_X25: i32;
}
#[cfg(not(test))]
fn host_pf() -> [i64; 44] { unsafe { [PF_ALG as i64, PF_APPLETALK as i64, PF_ASH as i64, PF_ATMPVC as i64, PF_ATMSVC as i64, PF_AX25 as i64, PF_BLUETOOTH as i64, PF_BRIDGE as i64, PF_CAIF as i64, PF_ECONET as i64, PF_FILE as i64, PF_IB as i64, PF_IEEE802154 as i64, PF_INET as i64, PF_INET6 as i64, PF_IPX as i64, PF_IRDA as i64, PF_ISDN as i64, PF_IUCV as i64, PF_KCM as i64, PF_KEY as i64, PF_LLC as i64, PF_LOCAL as i64, PF_MAX as i64, PF_MPLS as i64, PF_NETBEUI as i64, PF_NETLINK as i64, PF_NETROM as i64, PF_NFC as i64, PF_PACKET as i64, PF_PHONET as i64, PF_PPPOX as i64, PF_RDS as i64, PF_ROSE as i64, PF_ROUTE as i64, PF_RXRPC as i64, PF_SECURITY as i64, PF_SNA as i64, PF_TIPC as i64, PF_UNIX as i64, PF_UNSPEC as i64, PF_VSOCK as i64, PF_WANPIPE as i64, PF_X25 as i64] } }
#[cfg(test)]
fn host_pf() -> [i64; 44] { crate::xlate::test_host(&WINDOWS_pf, &XNU_pf) }
pub static NAMES_pf: [&str; 44] = ["PF_ALG", "PF_APPLETALK", "PF_ASH", "PF_ATMPVC", "PF_ATMSVC", "PF_AX25", "PF_BLUETOOTH", "PF_BRIDGE", "PF_CAIF", "PF_ECONET", "PF_FILE", "PF_IB", "PF_IEEE802154", "PF_INET", "PF_INET6", "PF_IPX", "PF_IRDA", "PF_ISDN", "PF_IUCV", "PF_KCM", "PF_KEY", "PF_LLC", "PF_LOCAL", "PF_MAX", "PF_MPLS", "PF_NETBEUI", "PF_NETLINK", "PF_NETROM", "PF_NFC", "PF_PACKET", "PF_PHONET", "PF_PPPOX", "PF_RDS", "PF_ROSE", "PF_ROUTE", "PF_RXRPC", "PF_SECURITY", "PF_SNA", "PF_TIPC", "PF_UNIX", "PF_UNSPEC", "PF_VSOCK", "PF_WANPIPE", "PF_X25"];
pub static LINUX_pf: [i64; 44] = [38, 5, 18, 8, 20, 3, 31, 7, 37, 19, 1, 27, 36, 2, 10, 4, 23, 34, 32, 41, 15, 26, 1, 42, 28, 13, 16, 6, 39, 17, 35, 24, 21, 11, 16, 33, 14, 22, 30, 1, 0, 40, 25, 9];
pub static WINDOWS_pf: [i64; 44] = [0, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 0, 0, 0, 0, 0, 0, 0, 0, 35, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 1, 0, 0, 0, 0];
pub static XNU_pf: [i64; 44] = [0, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 30, 23, 0, 28, 0, 0, 29, 0, 1, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 17, 0, 0, 11, 0, 1, 0, 0, 0, 0];
static mut HOST_pf: [i64; 44] = [0; 44];
static STATE_pf: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn pf() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_pf, &LINUX_pf, &STATE_pf, &raw mut HOST_pf, host_pf)
}
// ---- so (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static SOL_SOCKET: i32;
static SO_ACCEPTCONN: i32;
static SO_BROADCAST: i32;
static SO_DEBUG: i32;
static SO_DONTROUTE: i32;
static SO_ERROR: i32;
static SO_KEEPALIVE: i32;
static SO_LINGER: i32;
static SO_OOBINLINE: i32;
static SO_RCVBUF: i32;
static SO_RCVLOWAT: i32;
static SO_RCVTIMEO: i32;
static SO_REUSEADDR: i32;
static SO_REUSEPORT: i32;
static SO_SNDBUF: i32;
static SO_SNDLOWAT: i32;
static SO_SNDTIMEO: i32;
static SO_TYPE: i32;
static SO_USELOOPBACK: i32;
}
#[cfg(not(test))]
fn host_so() -> [i64; 19] { unsafe { [SOL_SOCKET as i64, SO_ACCEPTCONN as i64, SO_BROADCAST as i64, SO_DEBUG as i64, SO_DONTROUTE as i64, SO_ERROR as i64, SO_KEEPALIVE as i64, SO_LINGER as i64, SO_OOBINLINE as i64, SO_RCVBUF as i64, SO_RCVLOWAT as i64, SO_RCVTIMEO as i64, SO_REUSEADDR as i64, SO_REUSEPORT as i64, SO_SNDBUF as i64, SO_SNDLOWAT as i64, SO_SNDTIMEO as i64, SO_TYPE as i64, SO_USELOOPBACK as i64] } }
#[cfg(test)]
fn host_so() -> [i64; 19] { crate::xlate::test_host(&WINDOWS_so, &XNU_so) }
pub static NAMES_so: [&str; 19] = ["SOL_SOCKET", "SO_ACCEPTCONN", "SO_BROADCAST", "SO_DEBUG", "SO_DONTROUTE", "SO_ERROR", "SO_KEEPALIVE", "SO_LINGER", "SO_OOBINLINE", "SO_RCVBUF", "SO_RCVLOWAT", "SO_RCVTIMEO", "SO_REUSEADDR", "SO_REUSEPORT", "SO_SNDBUF", "SO_SNDLOWAT", "SO_SNDTIMEO", "SO_TYPE", "SO_USELOOPBACK"];
pub static LINUX_so: [i64; 19] = [1, 30, 6, 1, 5, 4, 9, 13, 10, 8, 18, 20, 2, 15, 7, 19, 21, 3, 0];
pub static WINDOWS_so: [i64; 19] = [65535, 2, 32, 1, 16, 4103, 8, 128, 256, 4098, 4100, 4102, -5, 0, 4097, 4099, 4101, 4104, 64];
pub static XNU_so: [i64; 19] = [65535, 2, 32, 1, 16, 4103, 8, 4224, 256, 4098, 4100, 4102, 4, 512, 4097, 4099, 4101, 4104, 64];
static mut HOST_so: [i64; 19] = [0; 19];
static STATE_so: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn so() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_so, &LINUX_so, &STATE_so, &raw mut HOST_so, host_so)
}
// ---- tcp (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static TCP_CC_INFO: i32;
static TCP_CONGESTION: i32;
static TCP_COOKIE_TRANSACTIONS: i32;
static TCP_CORK: i32;
static TCP_DEFER_ACCEPT: i32;
static TCP_FASTOPEN: i32;
static TCP_FASTOPEN_CONNECT: i32;
static TCP_INFO: i32;
static TCP_KEEPCNT: i32;
static TCP_KEEPIDLE: i32;
static TCP_KEEPINTVL: i32;
static TCP_LINGER2: i32;
static TCP_MAXSEG: i32;
static TCP_MD5SIG: i32;
static TCP_MD5SIG_MAXKEYLEN: i32;
static TCP_NODELAY: i32;
static TCP_NOTSENT_LOWAT: i32;
static TCP_QUEUE_SEQ: i32;
static TCP_QUICKACK: i32;
static TCP_REPAIR: i32;
static TCP_REPAIR_OPTIONS: i32;
static TCP_REPAIR_QUEUE: i32;
static TCP_SAVED_SYN: i32;
static TCP_SAVE_SYN: i32;
static TCP_SYNCNT: i32;
static TCP_THIN_DUPACK: i32;
static TCP_THIN_LINEAR_TIMEOUTS: i32;
static TCP_TIMESTAMP: i32;
static TCP_ULP: i32;
static TCP_USER_TIMEOUT: i32;
static TCP_WINDOW_CLAMP: i32;
}
#[cfg(not(test))]
fn host_tcp() -> [i64; 31] { unsafe { [TCP_CC_INFO as i64, TCP_CONGESTION as i64, TCP_COOKIE_TRANSACTIONS as i64, TCP_CORK as i64, TCP_DEFER_ACCEPT as i64, TCP_FASTOPEN as i64, TCP_FASTOPEN_CONNECT as i64, TCP_INFO as i64, TCP_KEEPCNT as i64, TCP_KEEPIDLE as i64, TCP_KEEPINTVL as i64, TCP_LINGER2 as i64, TCP_MAXSEG as i64, TCP_MD5SIG as i64, TCP_MD5SIG_MAXKEYLEN as i64, TCP_NODELAY as i64, TCP_NOTSENT_LOWAT as i64, TCP_QUEUE_SEQ as i64, TCP_QUICKACK as i64, TCP_REPAIR as i64, TCP_REPAIR_OPTIONS as i64, TCP_REPAIR_QUEUE as i64, TCP_SAVED_SYN as i64, TCP_SAVE_SYN as i64, TCP_SYNCNT as i64, TCP_THIN_DUPACK as i64, TCP_THIN_LINEAR_TIMEOUTS as i64, TCP_TIMESTAMP as i64, TCP_ULP as i64, TCP_USER_TIMEOUT as i64, TCP_WINDOW_CLAMP as i64] } }
#[cfg(test)]
fn host_tcp() -> [i64; 31] { crate::xlate::test_host(&WINDOWS_tcp, &XNU_tcp) }
pub static NAMES_tcp: [&str; 31] = ["TCP_CC_INFO", "TCP_CONGESTION", "TCP_COOKIE_TRANSACTIONS", "TCP_CORK", "TCP_DEFER_ACCEPT", "TCP_FASTOPEN", "TCP_FASTOPEN_CONNECT", "TCP_INFO", "TCP_KEEPCNT", "TCP_KEEPIDLE", "TCP_KEEPINTVL", "TCP_LINGER2", "TCP_MAXSEG", "TCP_MD5SIG", "TCP_MD5SIG_MAXKEYLEN", "TCP_NODELAY", "TCP_NOTSENT_LOWAT", "TCP_QUEUE_SEQ", "TCP_QUICKACK", "TCP_REPAIR", "TCP_REPAIR_OPTIONS", "TCP_REPAIR_QUEUE", "TCP_SAVED_SYN", "TCP_SAVE_SYN", "TCP_SYNCNT", "TCP_THIN_DUPACK", "TCP_THIN_LINEAR_TIMEOUTS", "TCP_TIMESTAMP", "TCP_ULP", "TCP_USER_TIMEOUT", "TCP_WINDOW_CLAMP"];
pub static LINUX_tcp: [i64; 31] = [26, 13, 15, 3, 9, 23, 30, 11, 6, 4, 5, 8, 2, 14, 80, 1, 25, 21, 12, 19, 22, 20, 28, 27, 7, 17, 16, 24, 31, 18, 10];
pub static WINDOWS_tcp: [i64; 31] = [0, 0, 0, 0, 0, 15, 0, 0, 16, 3, 17, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
pub static XNU_tcp: [i64; 31] = [0, 0, 0, 4, 0, 261, 0, 512, 258, 0, 257, 0, 2, 0, 0, 1, 513, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
static mut HOST_tcp: [i64; 31] = [0; 31];
static STATE_tcp: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn tcp() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_tcp, &LINUX_tcp, &STATE_tcp, &raw mut HOST_tcp, host_tcp)
}
// ---- ip (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static IP_ADD_MEMBERSHIP: i32;
static IP_DROP_MEMBERSHIP: i32;
static IP_HDRINCL: i32;
static IP_MTU: i32;
static IP_MULTICAST_IF: i32;
static IP_MULTICAST_LOOP: i32;
static IP_MULTICAST_TTL: i32;
static IP_OPTIONS: i32;
static IP_PKTINFO: i32;
static IP_RECVTOS: i32;
static IP_RECVTTL: i32;
static IP_TOS: i32;
static IP_TTL: i32;
}
#[cfg(not(test))]
fn host_ip() -> [i64; 13] { unsafe { [IP_ADD_MEMBERSHIP as i64, IP_DROP_MEMBERSHIP as i64, IP_HDRINCL as i64, IP_MTU as i64, IP_MULTICAST_IF as i64, IP_MULTICAST_LOOP as i64, IP_MULTICAST_TTL as i64, IP_OPTIONS as i64, IP_PKTINFO as i64, IP_RECVTOS as i64, IP_RECVTTL as i64, IP_TOS as i64, IP_TTL as i64] } }
#[cfg(test)]
fn host_ip() -> [i64; 13] { crate::xlate::test_host(&WINDOWS_ip, &XNU_ip) }
pub static NAMES_ip: [&str; 13] = ["IP_ADD_MEMBERSHIP", "IP_DROP_MEMBERSHIP", "IP_HDRINCL", "IP_MTU", "IP_MULTICAST_IF", "IP_MULTICAST_LOOP", "IP_MULTICAST_TTL", "IP_OPTIONS", "IP_PKTINFO", "IP_RECVTOS", "IP_RECVTTL", "IP_TOS", "IP_TTL"];
pub static LINUX_ip: [i64; 13] = [35, 36, 3, 14, 32, 34, 33, 4, 8, 13, 12, 1, 2];
pub static WINDOWS_ip: [i64; 13] = [12, 13, 2, 73, 9, 11, 10, 1, 19, 40, 21, 3, 4];
pub static XNU_ip: [i64; 13] = [12, 13, 2, 0, 9, 11, 10, 1, 26, 0, 24, 3, 4];
static mut HOST_ip: [i64; 13] = [0; 13];
static STATE_ip: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn ip() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_ip, &LINUX_ip, &STATE_ip, &raw mut HOST_ip, host_ip)
}
// ---- ipv6 (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static IPV6_CHECKSUM: i32;
static IPV6_DONTFRAG: i32;
static IPV6_HOPLIMIT: i32;
static IPV6_HOPOPTS: i32;
static IPV6_JOIN_GROUP: i32;
static IPV6_LEAVE_GROUP: i32;
static IPV6_MULTICAST_HOPS: i32;
static IPV6_MULTICAST_IF: i32;
static IPV6_MULTICAST_LOOP: i32;
static IPV6_PKTINFO: i32;
static IPV6_RECVRTHDR: i32;
static IPV6_RECVTCLASS: i32;
static IPV6_RTHDR: i32;
static IPV6_TCLASS: i32;
static IPV6_UNICAST_HOPS: i32;
static IPV6_V6ONLY: i32;
}
#[cfg(not(test))]
fn host_ipv6() -> [i64; 16] { unsafe { [IPV6_CHECKSUM as i64, IPV6_DONTFRAG as i64, IPV6_HOPLIMIT as i64, IPV6_HOPOPTS as i64, IPV6_JOIN_GROUP as i64, IPV6_LEAVE_GROUP as i64, IPV6_MULTICAST_HOPS as i64, IPV6_MULTICAST_IF as i64, IPV6_MULTICAST_LOOP as i64, IPV6_PKTINFO as i64, IPV6_RECVRTHDR as i64, IPV6_RECVTCLASS as i64, IPV6_RTHDR as i64, IPV6_TCLASS as i64, IPV6_UNICAST_HOPS as i64, IPV6_V6ONLY as i64] } }
#[cfg(test)]
fn host_ipv6() -> [i64; 16] { crate::xlate::test_host(&WINDOWS_ipv6, &XNU_ipv6) }
pub static NAMES_ipv6: [&str; 16] = ["IPV6_CHECKSUM", "IPV6_DONTFRAG", "IPV6_HOPLIMIT", "IPV6_HOPOPTS", "IPV6_JOIN_GROUP", "IPV6_LEAVE_GROUP", "IPV6_MULTICAST_HOPS", "IPV6_MULTICAST_IF", "IPV6_MULTICAST_LOOP", "IPV6_PKTINFO", "IPV6_RECVRTHDR", "IPV6_RECVTCLASS", "IPV6_RTHDR", "IPV6_TCLASS", "IPV6_UNICAST_HOPS", "IPV6_V6ONLY"];
pub static LINUX_ipv6: [i64; 16] = [7, 62, 52, 54, 20, 21, 18, 17, 19, 50, 56, 66, 57, 67, 16, 26];
pub static WINDOWS_ipv6: [i64; 16] = [26, 14, 21, 1, 12, 13, 10, 9, 11, 19, 38, 40, 32, 39, 4, 27];
pub static XNU_ipv6: [i64; 16] = [26, 0, 0, 0, 12, 13, 10, 9, 11, 0, 0, 35, 0, 36, 4, 27];
static mut HOST_ipv6: [i64; 16] = [0; 16];
static STATE_ipv6: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn ipv6() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_ipv6, &LINUX_ipv6, &STATE_ipv6, &raw mut HOST_ipv6, host_ipv6)
}
// ---- sig (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static SIGABRT: i32;
static SIGALRM: i32;
static SIGBUS: i32;
static SIGCHLD: i32;
static SIGCONT: i32;
static SIGEMT: i32;
static SIGFPE: i32;
static SIGHUP: i32;
static SIGILL: i32;
static SIGINFO: i32;
static SIGINT: i32;
static SIGIO: i32;
static SIGKILL: i32;
static SIGPIPE: i32;
static SIGPROF: i32;
static SIGPWR: i32;
static SIGQUIT: i32;
static SIGRTMAX: i32;
static SIGRTMIN: i32;
static SIGSEGV: i32;
static SIGSTKFLT: i32;
static SIGSTOP: i32;
static SIGSYS: i32;
static SIGTERM: i32;
static SIGTHR: i32;
static SIGTRAP: i32;
static SIGTSTP: i32;
static SIGTTIN: i32;
static SIGTTOU: i32;
static SIGURG: i32;
static SIGUSR1: i32;
static SIGUSR2: i32;
static SIGVTALRM: i32;
static SIGWINCH: i32;
static SIGXCPU: i32;
static SIGXFSZ: i32;
}
#[cfg(not(test))]
fn host_sig() -> [i64; 36] { unsafe { [SIGABRT as i64, SIGALRM as i64, SIGBUS as i64, SIGCHLD as i64, SIGCONT as i64, SIGEMT as i64, SIGFPE as i64, SIGHUP as i64, SIGILL as i64, SIGINFO as i64, SIGINT as i64, SIGIO as i64, SIGKILL as i64, SIGPIPE as i64, SIGPROF as i64, SIGPWR as i64, SIGQUIT as i64, SIGRTMAX as i64, SIGRTMIN as i64, SIGSEGV as i64, SIGSTKFLT as i64, SIGSTOP as i64, SIGSYS as i64, SIGTERM as i64, SIGTHR as i64, SIGTRAP as i64, SIGTSTP as i64, SIGTTIN as i64, SIGTTOU as i64, SIGURG as i64, SIGUSR1 as i64, SIGUSR2 as i64, SIGVTALRM as i64, SIGWINCH as i64, SIGXCPU as i64, SIGXFSZ as i64] } }
#[cfg(test)]
fn host_sig() -> [i64; 36] { crate::xlate::test_host(&WINDOWS_sig, &XNU_sig) }
pub static NAMES_sig: [&str; 36] = ["SIGABRT", "SIGALRM", "SIGBUS", "SIGCHLD", "SIGCONT", "SIGEMT", "SIGFPE", "SIGHUP", "SIGILL", "SIGINFO", "SIGINT", "SIGIO", "SIGKILL", "SIGPIPE", "SIGPROF", "SIGPWR", "SIGQUIT", "SIGRTMAX", "SIGRTMIN", "SIGSEGV", "SIGSTKFLT", "SIGSTOP", "SIGSYS", "SIGTERM", "SIGTHR", "SIGTRAP", "SIGTSTP", "SIGTTIN", "SIGTTOU", "SIGURG", "SIGUSR1", "SIGUSR2", "SIGVTALRM", "SIGWINCH", "SIGXCPU", "SIGXFSZ"];
pub static LINUX_sig: [i64; 36] = [6, 14, 7, 17, 18, 64, 8, 1, 4, 63, 2, 29, 9, 13, 27, 30, 3, 64, 32, 11, 16, 19, 31, 15, 32, 5, 20, 21, 22, 23, 10, 12, 26, 28, 24, 25];
pub static WINDOWS_sig: [i64; 36] = [6, 14, 7, 17, 18, 64, 8, 1, 4, 63, 2, 29, 9, 13, 27, 30, 3, 64, 32, 11, 0, 19, 31, 15, 32, 5, 20, 21, 22, 23, 10, 12, 26, 28, 24, 25];
pub static XNU_sig: [i64; 36] = [6, 14, 10, 20, 19, 7, 8, 1, 4, 29, 2, 23, 9, 13, 27, 30, 3, 0, 0, 11, 0, 17, 12, 15, 7, 5, 18, 21, 22, 16, 30, 31, 26, 28, 24, 25];
static mut HOST_sig: [i64; 36] = [0; 36];
static STATE_sig: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn sig() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_sig, &LINUX_sig, &STATE_sig, &raw mut HOST_sig, host_sig)
}
// ---- clock (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static CLOCK_BOOTTIME: i32;
static CLOCK_MONOTONIC: i32;
static CLOCK_MONOTONIC_COARSE: i32;
static CLOCK_MONOTONIC_RAW: i32;
static CLOCK_PROCESS_CPUTIME_ID: i32;
static CLOCK_REALTIME: i32;
static CLOCK_REALTIME_COARSE: i32;
static CLOCK_THREAD_CPUTIME_ID: i32;
}
#[cfg(not(test))]
fn host_clock() -> [i64; 8] { unsafe { [CLOCK_BOOTTIME as i64, CLOCK_MONOTONIC as i64, CLOCK_MONOTONIC_COARSE as i64, CLOCK_MONOTONIC_RAW as i64, CLOCK_PROCESS_CPUTIME_ID as i64, CLOCK_REALTIME as i64, CLOCK_REALTIME_COARSE as i64, CLOCK_THREAD_CPUTIME_ID as i64] } }
#[cfg(test)]
fn host_clock() -> [i64; 8] { crate::xlate::test_host(&WINDOWS_clock, &XNU_clock) }
pub static NAMES_clock: [&str; 8] = ["CLOCK_BOOTTIME", "CLOCK_MONOTONIC", "CLOCK_MONOTONIC_COARSE", "CLOCK_MONOTONIC_RAW", "CLOCK_PROCESS_CPUTIME_ID", "CLOCK_REALTIME", "CLOCK_REALTIME_COARSE", "CLOCK_THREAD_CPUTIME_ID"];
pub static LINUX_clock: [i64; 8] = [7, 1, 6, 4, 2, 0, 5, 3];
pub static WINDOWS_clock: [i64; 8] = [3, 1, 6, 1, 4, 0, 2, 5];
pub static XNU_clock: [i64; 8] = [6, 8, 9, 127, 12, 0, 0, 16];
static mut HOST_clock: [i64; 8] = [0; 8];
static STATE_clock: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn clock() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_clock, &LINUX_clock, &STATE_clock, &raw mut HOST_clock, host_clock)
}
// ---- fcntl (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static FREAD: i32;
static FWRITE: i32;
static F_DUPFD_CLOEXEC: i32;
static F_GETLEASE: i32;
static F_GETLK: i32;
static F_GETOWN_EX: i32;
static F_GETPIPE_SZ: i32;
static F_GETSIG: i32;
static F_MAXFD: i32;
static F_NOTIFY: i32;
static F_OFD_GETLK: i32;
static F_OFD_SETLK: i32;
static F_OFD_SETLKW: i32;
static F_RDLCK: i32;
static F_SETLEASE: i32;
static F_SETLK: i32;
static F_SETLKW: i32;
static F_SETOWN_EX: i32;
static F_SETPIPE_SZ: i32;
static F_SETSIG: i32;
static F_UNLCK: i32;
static F_WRLCK: i32;
}
#[cfg(not(test))]
fn host_fcntl() -> [i64; 22] { unsafe { [FREAD as i64, FWRITE as i64, F_DUPFD_CLOEXEC as i64, F_GETLEASE as i64, F_GETLK as i64, F_GETOWN_EX as i64, F_GETPIPE_SZ as i64, F_GETSIG as i64, F_MAXFD as i64, F_NOTIFY as i64, F_OFD_GETLK as i64, F_OFD_SETLK as i64, F_OFD_SETLKW as i64, F_RDLCK as i64, F_SETLEASE as i64, F_SETLK as i64, F_SETLKW as i64, F_SETOWN_EX as i64, F_SETPIPE_SZ as i64, F_SETSIG as i64, F_UNLCK as i64, F_WRLCK as i64] } }
#[cfg(test)]
fn host_fcntl() -> [i64; 22] { crate::xlate::test_host(&WINDOWS_fcntl, &XNU_fcntl) }
pub static NAMES_fcntl: [&str; 22] = ["FREAD", "FWRITE", "F_DUPFD_CLOEXEC", "F_GETLEASE", "F_GETLK", "F_GETOWN_EX", "F_GETPIPE_SZ", "F_GETSIG", "F_MAXFD", "F_NOTIFY", "F_OFD_GETLK", "F_OFD_SETLK", "F_OFD_SETLKW", "F_RDLCK", "F_SETLEASE", "F_SETLK", "F_SETLKW", "F_SETOWN_EX", "F_SETPIPE_SZ", "F_SETSIG", "F_UNLCK", "F_WRLCK"];
pub static LINUX_fcntl: [i64; 22] = [0, 0, 1030, 1025, 5, 16, 1032, 11, -1, 1026, 36, 37, 38, 0, 1024, 6, 7, 15, 1031, 10, 2, 1];
pub static WINDOWS_fcntl: [i64; 22] = [0, 0, 1030, -1, 5, -1, -1, -1, -1, -1, -1, -1, -1, 0, -1, 6, 7, -1, -1, -1, 2, 1];
pub static XNU_fcntl: [i64; 22] = [1, 2, 67, -1, 7, -1, -1, -1, -1, -1, -1, -1, -1, 1, -1, 8, 9, -1, -1, -1, 2, 3];
static mut HOST_fcntl: [i64; 22] = [0; 22];
static STATE_fcntl: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn fcntl() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_fcntl, &LINUX_fcntl, &STATE_fcntl, &raw mut HOST_fcntl, host_fcntl)
}
// ---- fcntl2 (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static F_BARRIERFSYNC: i32;
static F_DUPFD: i32;
static F_FULLFSYNC: i32;
static F_GETFD: i32;
static F_GETFL: i32;
static F_GETOWN: i32;
static F_NOCACHE: i32;
static F_SETFD: i32;
static F_SETFL: i32;
static F_SETOWN: i32;
}
#[cfg(not(test))]
fn host_fcntl2() -> [i64; 10] { unsafe { [F_BARRIERFSYNC as i64, F_DUPFD as i64, F_FULLFSYNC as i64, F_GETFD as i64, F_GETFL as i64, F_GETOWN as i64, F_NOCACHE as i64, F_SETFD as i64, F_SETFL as i64, F_SETOWN as i64] } }
#[cfg(test)]
fn host_fcntl2() -> [i64; 10] { crate::xlate::test_host(&WINDOWS_fcntl2, &XNU_fcntl2) }
pub static NAMES_fcntl2: [&str; 10] = ["F_BARRIERFSYNC", "F_DUPFD", "F_FULLFSYNC", "F_GETFD", "F_GETFL", "F_GETOWN", "F_NOCACHE", "F_SETFD", "F_SETFL", "F_SETOWN"];
pub static LINUX_fcntl2: [i64; 10] = [-1, 0, -1, 1, 3, 9, -1, 2, 4, 8];
pub static WINDOWS_fcntl2: [i64; 10] = [-1, 0, -1, 1, 3, -1, -1, 2, 4, -1];
pub static XNU_fcntl2: [i64; 10] = [85, 0, 51, 1, 3, 5, 48, 2, 4, 6];
static mut HOST_fcntl2: [i64; 10] = [0; 10];
static STATE_fcntl2: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn fcntl2() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_fcntl2, &LINUX_fcntl2, &STATE_fcntl2, &raw mut HOST_fcntl2, host_fcntl2)
}
// ---- fcntl3 (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static FD_CLOEXEC: i32;
static F_GETNOSIGPIPE: i32;
static F_GETPATH: i32;
static F_SETNOSIGPIPE: i32;
}
#[cfg(not(test))]
fn host_fcntl3() -> [i64; 4] { unsafe { [FD_CLOEXEC as i64, F_GETNOSIGPIPE as i64, F_GETPATH as i64, F_SETNOSIGPIPE as i64] } }
#[cfg(test)]
fn host_fcntl3() -> [i64; 4] { crate::xlate::test_host(&WINDOWS_fcntl3, &XNU_fcntl3) }
pub static NAMES_fcntl3: [&str; 4] = ["FD_CLOEXEC", "F_GETNOSIGPIPE", "F_GETPATH", "F_SETNOSIGPIPE"];
pub static LINUX_fcntl3: [i64; 4] = [1, -1, -1, -1];
pub static WINDOWS_fcntl3: [i64; 4] = [1, -1, -1, -1];
pub static XNU_fcntl3: [i64; 4] = [1, 74, 50, 73];
static mut HOST_fcntl3: [i64; 4] = [0; 4];
static STATE_fcntl3: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn fcntl3() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_fcntl3, &LINUX_fcntl3, &STATE_fcntl3, &raw mut HOST_fcntl3, host_fcntl3)
}
// ---- ioctl (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static FIOASYNC: u32;
static FIOCLEX: u32;
static FIONBIO: u32;
static FIONCLEX: u32;
static FIONREAD: u32;
static SIOCADDDLCI: u64;
static SIOCADDMULTI: u64;
static SIOCADDRT: u64;
static SIOCDARP: u64;
static SIOCDELDLCI: u64;
static SIOCDELMULTI: u64;
static SIOCDELRT: u64;
static SIOCDEVPRIVATE: u64;
static SIOCDIFADDR: u64;
static SIOCDRARP: u64;
static SIOCGARP: u64;
static SIOCGIFADDR: u64;
static SIOCGIFBR: u64;
static SIOCGIFBRDADDR: u64;
static SIOCGIFCONF: u64;
static SIOCGIFCOUNT: u64;
static SIOCGIFDSTADDR: u64;
static SIOCGIFENCAP: u64;
static SIOCGIFFLAGS: u64;
static SIOCGIFHWADDR: u64;
static SIOCGIFINDEX: u64;
static SIOCGIFMAP: u64;
static SIOCGIFMEM: u64;
static SIOCGIFMETRIC: u64;
static SIOCGIFMTU: u64;
static SIOCGIFNAME: u64;
static SIOCGIFNETMASK: u64;
static SIOCGIFPFLAGS: u64;
static SIOCGIFSLAVE: u64;
static SIOCGIFTXQLEN: u64;
static SIOCGPGRP: u64;
static SIOCGRARP: u64;
static SIOCGSTAMP: u64;
static SIOCGSTAMPNS: u64;
static SIOCPROTOPRIVATE: u64;
static SIOCRTMSG: u64;
static SIOCSARP: u64;
static SIOCSIFADDR: u64;
static SIOCSIFBR: u64;
static SIOCSIFBRDADDR: u64;
static SIOCSIFDSTADDR: u64;
static SIOCSIFENCAP: u64;
static SIOCSIFFLAGS: u64;
static SIOCSIFHWADDR: u64;
static SIOCSIFHWBROADCAST: u64;
static SIOCSIFLINK: u64;
static SIOCSIFMAP: u64;
static SIOCSIFMEM: u64;
static SIOCSIFMETRIC: u64;
static SIOCSIFMTU: u64;
static SIOCSIFNAME: u64;
static SIOCSIFNETMASK: u64;
static SIOCSIFPFLAGS: u64;
static SIOCSIFSLAVE: u64;
static SIOCSIFTXQLEN: u64;
static SIOCSPGRP: u64;
static SIOCSRARP: u64;
static SIOGIFINDEX: u64;
}
#[cfg(not(test))]
fn host_ioctl() -> [i64; 63] { unsafe { [FIOASYNC as i64, FIOCLEX as i64, FIONBIO as i64, FIONCLEX as i64, FIONREAD as i64, SIOCADDDLCI as i64, SIOCADDMULTI as i64, SIOCADDRT as i64, SIOCDARP as i64, SIOCDELDLCI as i64, SIOCDELMULTI as i64, SIOCDELRT as i64, SIOCDEVPRIVATE as i64, SIOCDIFADDR as i64, SIOCDRARP as i64, SIOCGARP as i64, SIOCGIFADDR as i64, SIOCGIFBR as i64, SIOCGIFBRDADDR as i64, SIOCGIFCONF as i64, SIOCGIFCOUNT as i64, SIOCGIFDSTADDR as i64, SIOCGIFENCAP as i64, SIOCGIFFLAGS as i64, SIOCGIFHWADDR as i64, SIOCGIFINDEX as i64, SIOCGIFMAP as i64, SIOCGIFMEM as i64, SIOCGIFMETRIC as i64, SIOCGIFMTU as i64, SIOCGIFNAME as i64, SIOCGIFNETMASK as i64, SIOCGIFPFLAGS as i64, SIOCGIFSLAVE as i64, SIOCGIFTXQLEN as i64, SIOCGPGRP as i64, SIOCGRARP as i64, SIOCGSTAMP as i64, SIOCGSTAMPNS as i64, SIOCPROTOPRIVATE as i64, SIOCRTMSG as i64, SIOCSARP as i64, SIOCSIFADDR as i64, SIOCSIFBR as i64, SIOCSIFBRDADDR as i64, SIOCSIFDSTADDR as i64, SIOCSIFENCAP as i64, SIOCSIFFLAGS as i64, SIOCSIFHWADDR as i64, SIOCSIFHWBROADCAST as i64, SIOCSIFLINK as i64, SIOCSIFMAP as i64, SIOCSIFMEM as i64, SIOCSIFMETRIC as i64, SIOCSIFMTU as i64, SIOCSIFNAME as i64, SIOCSIFNETMASK as i64, SIOCSIFPFLAGS as i64, SIOCSIFSLAVE as i64, SIOCSIFTXQLEN as i64, SIOCSPGRP as i64, SIOCSRARP as i64, SIOGIFINDEX as i64] } }
#[cfg(test)]
fn host_ioctl() -> [i64; 63] { crate::xlate::test_host(&WINDOWS_ioctl, &XNU_ioctl) }
pub static NAMES_ioctl: [&str; 63] = ["FIOASYNC", "FIOCLEX", "FIONBIO", "FIONCLEX", "FIONREAD", "SIOCADDDLCI", "SIOCADDMULTI", "SIOCADDRT", "SIOCDARP", "SIOCDELDLCI", "SIOCDELMULTI", "SIOCDELRT", "SIOCDEVPRIVATE", "SIOCDIFADDR", "SIOCDRARP", "SIOCGARP", "SIOCGIFADDR", "SIOCGIFBR", "SIOCGIFBRDADDR", "SIOCGIFCONF", "SIOCGIFCOUNT", "SIOCGIFDSTADDR", "SIOCGIFENCAP", "SIOCGIFFLAGS", "SIOCGIFHWADDR", "SIOCGIFINDEX", "SIOCGIFMAP", "SIOCGIFMEM", "SIOCGIFMETRIC", "SIOCGIFMTU", "SIOCGIFNAME", "SIOCGIFNETMASK", "SIOCGIFPFLAGS", "SIOCGIFSLAVE", "SIOCGIFTXQLEN", "SIOCGPGRP", "SIOCGRARP", "SIOCGSTAMP", "SIOCGSTAMPNS", "SIOCPROTOPRIVATE", "SIOCRTMSG", "SIOCSARP", "SIOCSIFADDR", "SIOCSIFBR", "SIOCSIFBRDADDR", "SIOCSIFDSTADDR", "SIOCSIFENCAP", "SIOCSIFFLAGS", "SIOCSIFHWADDR", "SIOCSIFHWBROADCAST", "SIOCSIFLINK", "SIOCSIFMAP", "SIOCSIFMEM", "SIOCSIFMETRIC", "SIOCSIFMTU", "SIOCSIFNAME", "SIOCSIFNETMASK", "SIOCSIFPFLAGS", "SIOCSIFSLAVE", "SIOCSIFTXQLEN", "SIOCSPGRP", "SIOCSRARP", "SIOGIFINDEX"];
pub static LINUX_ioctl: [i64; 63] = [21586, 21585, 21537, 21584, 21531, 35200, 35121, 35083, 35155, 35201, 35122, 35084, 35312, 35126, 35168, 35156, 35093, 35136, 35097, 35090, 35128, 35095, 35109, 35091, 35111, 35123, 35184, 35103, 35101, 35105, 35088, 35099, 35125, 35113, 35138, 35076, 35169, 35078, 35079, 35296, 35085, 35157, 35094, 35137, 35098, 35096, 35110, 35092, 35108, 35127, 35089, 35185, 35104, 35102, 35106, 35107, 35100, 35124, 35120, 35139, 35074, 35170, 35123];
pub static WINDOWS_ioctl: [i64; 63] = [2147772029, 21585, 2147772030, 21584, 1074030207, 0, 35121, 0, 0, 0, 35122, 0, 0, 35126, 0, 0, 35093, 0, 35097, 35090, 0, 35095, 0, 35091, 0, 0, 0, 0, 35101, 35105, 0, 35099, 0, 0, 0, 35076, 0, 0, 0, 0, 0, 0, 35094, 0, 35098, 35096, 0, 35092, 0, 0, 0, 0, 0, 35102, 35106, 0, 35100, 0, 0, 0, 35074, 0, 0];
pub static XNU_ioctl: [i64; 63] = [2147772029, 536897025, 2147772030, 536897026, 1074030207, 0, 2149607729, 0, 0, 0, 2149607730, 0, 0, 2149607705, 0, 0, 3223349537, 0, 3223349539, 3222038820, 0, 3223349538, 0, 3223349521, 0, 0, 0, 0, 3223349527, 3223349555, 0, 3223349541, 0, 0, 0, 1074033417, 0, 0, 0, 0, 0, 0, 2149607692, 0, 2149607699, 2149607694, 0, 2149607696, 0, 0, 0, 0, 0, 2149607704, 2149607732, 0, 2149607702, 0, 0, 0, 2147775240, 0, 0];
static mut HOST_ioctl: [i64; 63] = [0; 63];
static STATE_ioctl: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn ioctl() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_ioctl, &LINUX_ioctl, &STATE_ioctl, &raw mut HOST_ioctl, host_ioctl)
}
// ---- access (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static R_OK: u32;
static W_OK: i32;
static X_OK: i32;
}
#[cfg(not(test))]
fn host_access() -> [i64; 3] { unsafe { [R_OK as i64, W_OK as i64, X_OK as i64] } }
#[cfg(test)]
fn host_access() -> [i64; 3] { crate::xlate::test_host(&WINDOWS_access, &XNU_access) }
pub static NAMES_access: [&str; 3] = ["R_OK", "W_OK", "X_OK"];
pub static LINUX_access: [i64; 3] = [4, 2, 1];
pub static WINDOWS_access: [i64; 3] = [2147483648, 1073741824, 536870912];
pub static XNU_access: [i64; 3] = [4, 2, 1];
static mut HOST_access: [i64; 3] = [0; 3];
static STATE_access: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn access() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_access, &LINUX_access, &STATE_access, &raw mut HOST_access, host_access)
}
// ---- lock (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static LOCK_EX: i32;
static LOCK_NB: i32;
static LOCK_SH: i32;
static LOCK_UN: i32;
}
#[cfg(not(test))]
fn host_lock() -> [i64; 4] { unsafe { [LOCK_EX as i64, LOCK_NB as i64, LOCK_SH as i64, LOCK_UN as i64] } }
#[cfg(test)]
fn host_lock() -> [i64; 4] { crate::xlate::test_host(&WINDOWS_lock, &XNU_lock) }
pub static NAMES_lock: [&str; 4] = ["LOCK_EX", "LOCK_NB", "LOCK_SH", "LOCK_UN"];
pub static LINUX_lock: [i64; 4] = [2, 4, 1, 8];
pub static WINDOWS_lock: [i64; 4] = [2, 1, 0, 8];
pub static XNU_lock: [i64; 4] = [2, 4, 1, 8];
static mut HOST_lock: [i64; 4] = [0; 4];
static STATE_lock: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn lock() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_lock, &LINUX_lock, &STATE_lock, &raw mut HOST_lock, host_lock)
}
// ---- madv (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static MADV_COLD: u32;
static MADV_COLLAPSE: u32;
static MADV_DODUMP: u32;
static MADV_DOFORK: u32;
static MADV_DONTDUMP: u32;
static MADV_DONTFORK: u32;
static MADV_DONTNEED: u32;
static MADV_DONTNEED_LOCKED: u32;
static MADV_FREE: u32;
static MADV_HUGEPAGE: u32;
static MADV_HWPOISON: u32;
static MADV_KEEPONFORK: u32;
static MADV_MERGEABLE: u32;
static MADV_NOHUGEPAGE: u32;
static MADV_NORMAL: u32;
static MADV_PAGEOUT: u32;
static MADV_POPULATE_READ: u32;
static MADV_POPULATE_WRITE: u32;
static MADV_RANDOM: u32;
static MADV_REMOVE: u32;
static MADV_SEQUENTIAL: u32;
static MADV_SOFT_OFFLINE: u32;
static MADV_UNMERGEABLE: u32;
static MADV_WILLNEED: u32;
static MADV_WIPEONFORK: u32;
static POSIX_FADV_DONTNEED: i32;
static POSIX_FADV_NORMAL: i32;
static POSIX_FADV_RANDOM: i32;
static POSIX_FADV_SEQUENTIAL: i32;
static POSIX_FADV_WILLNEED: i32;
static POSIX_MADV_DONTNEED: i32;
static POSIX_MADV_NORMAL: i32;
static POSIX_MADV_RANDOM: i32;
static POSIX_MADV_SEQUENTIAL: i32;
static POSIX_MADV_WILLNEED: i32;
}
#[cfg(not(test))]
fn host_madv() -> [i64; 35] { unsafe { [MADV_COLD as i64, MADV_COLLAPSE as i64, MADV_DODUMP as i64, MADV_DOFORK as i64, MADV_DONTDUMP as i64, MADV_DONTFORK as i64, MADV_DONTNEED as i64, MADV_DONTNEED_LOCKED as i64, MADV_FREE as i64, MADV_HUGEPAGE as i64, MADV_HWPOISON as i64, MADV_KEEPONFORK as i64, MADV_MERGEABLE as i64, MADV_NOHUGEPAGE as i64, MADV_NORMAL as i64, MADV_PAGEOUT as i64, MADV_POPULATE_READ as i64, MADV_POPULATE_WRITE as i64, MADV_RANDOM as i64, MADV_REMOVE as i64, MADV_SEQUENTIAL as i64, MADV_SOFT_OFFLINE as i64, MADV_UNMERGEABLE as i64, MADV_WILLNEED as i64, MADV_WIPEONFORK as i64, POSIX_FADV_DONTNEED as i64, POSIX_FADV_NORMAL as i64, POSIX_FADV_RANDOM as i64, POSIX_FADV_SEQUENTIAL as i64, POSIX_FADV_WILLNEED as i64, POSIX_MADV_DONTNEED as i64, POSIX_MADV_NORMAL as i64, POSIX_MADV_RANDOM as i64, POSIX_MADV_SEQUENTIAL as i64, POSIX_MADV_WILLNEED as i64] } }
#[cfg(test)]
fn host_madv() -> [i64; 35] { crate::xlate::test_host(&WINDOWS_madv, &XNU_madv) }
pub static NAMES_madv: [&str; 35] = ["MADV_COLD", "MADV_COLLAPSE", "MADV_DODUMP", "MADV_DOFORK", "MADV_DONTDUMP", "MADV_DONTFORK", "MADV_DONTNEED", "MADV_DONTNEED_LOCKED", "MADV_FREE", "MADV_HUGEPAGE", "MADV_HWPOISON", "MADV_KEEPONFORK", "MADV_MERGEABLE", "MADV_NOHUGEPAGE", "MADV_NORMAL", "MADV_PAGEOUT", "MADV_POPULATE_READ", "MADV_POPULATE_WRITE", "MADV_RANDOM", "MADV_REMOVE", "MADV_SEQUENTIAL", "MADV_SOFT_OFFLINE", "MADV_UNMERGEABLE", "MADV_WILLNEED", "MADV_WIPEONFORK", "POSIX_FADV_DONTNEED", "POSIX_FADV_NORMAL", "POSIX_FADV_RANDOM", "POSIX_FADV_SEQUENTIAL", "POSIX_FADV_WILLNEED", "POSIX_MADV_DONTNEED", "POSIX_MADV_NORMAL", "POSIX_MADV_RANDOM", "POSIX_MADV_SEQUENTIAL", "POSIX_MADV_WILLNEED"];
pub static LINUX_madv: [i64; 35] = [20, 25, 17, 11, 16, 10, 4, 24, 8, 14, 100, 19, 12, 15, 0, 21, 22, 23, 1, 9, 2, 101, 13, 3, 18, 4, 0, 1, 2, 3, 4, 0, 1, 2, 3];
pub static WINDOWS_madv: [i64; 35] = [127, 127, 127, 127, 127, 127, 127, 127, 8, 127, 127, 127, 127, 127, 0, 127, 127, 127, 1, 127, 2, 127, 127, 3, 127, 127, 0, 1, 2, 3, 127, 0, 1, 2, 3];
pub static XNU_madv: [i64; 35] = [127, 127, 127, 127, 127, 127, 4, 127, 5, 127, 127, 127, 127, 127, 0, 127, 127, 127, 1, 127, 2, 127, 127, 3, 127, 127, 0, 127, 127, 127, 4, 0, 1, 2, 3];
static mut HOST_madv: [i64; 35] = [0; 35];
static STATE_madv: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn madv() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_madv, &LINUX_madv, &STATE_madv, &raw mut HOST_madv, host_madv)
}
// ---- ss (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static SS_DISABLE: i32;
static SS_ONSTACK: i32;
}
#[cfg(not(test))]
fn host_ss() -> [i64; 2] { unsafe { [SS_DISABLE as i64, SS_ONSTACK as i64] } }
#[cfg(test)]
fn host_ss() -> [i64; 2] { crate::xlate::test_host(&WINDOWS_ss, &XNU_ss) }
pub static NAMES_ss: [&str; 2] = ["SS_DISABLE", "SS_ONSTACK"];
pub static LINUX_ss: [i64; 2] = [2, 1];
pub static WINDOWS_ss: [i64; 2] = [2, 1];
pub static XNU_ss: [i64; 2] = [4, 1];
static mut HOST_ss: [i64; 2] = [0; 2];
static STATE_ss: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn ss() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_ss, &LINUX_ss, &STATE_ss, &raw mut HOST_ss, host_ss)
}
// ---- scm (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static SCM_CREDENTIALS: i32;
static SCM_RIGHTS: i32;
static SCM_TIMESTAMP: i32;
static SCM_TIMESTAMPING: i32;
static SCM_TIMESTAMPNS: i32;
static SCM_WIFI_STATUS: i32;
}
#[cfg(not(test))]
fn host_scm() -> [i64; 6] { unsafe { [SCM_CREDENTIALS as i64, SCM_RIGHTS as i64, SCM_TIMESTAMP as i64, SCM_TIMESTAMPING as i64, SCM_TIMESTAMPNS as i64, SCM_WIFI_STATUS as i64] } }
#[cfg(test)]
fn host_scm() -> [i64; 6] { crate::xlate::test_host(&WINDOWS_scm, &XNU_scm) }
pub static NAMES_scm: [&str; 6] = ["SCM_CREDENTIALS", "SCM_RIGHTS", "SCM_TIMESTAMP", "SCM_TIMESTAMPING", "SCM_TIMESTAMPNS", "SCM_WIFI_STATUS"];
pub static LINUX_scm: [i64; 6] = [2, 1, 29, 37, 35, 41];
pub static WINDOWS_scm: [i64; 6] = [0, 1, 0, 0, 0, 0];
pub static XNU_scm: [i64; 6] = [0, 1, 2, 0, 0, 0];
static mut HOST_scm: [i64; 6] = [0; 6];
static STATE_scm: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn scm() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_scm, &LINUX_scm, &STATE_scm, &raw mut HOST_scm, host_scm)
}
// ---- limits (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static LINK_MAX: i32;
static MAX_CANON: i32;
static MAX_INPUT: i32;
static NGROUPS_MAX: i32;
static PIPE_BUF: i32;
static SOMAXCONN: i32;
}
#[cfg(not(test))]
fn host_limits() -> [i64; 6] { unsafe { [LINK_MAX as i64, MAX_CANON as i64, MAX_INPUT as i64, NGROUPS_MAX as i64, PIPE_BUF as i64, SOMAXCONN as i64] } }
#[cfg(test)]
fn host_limits() -> [i64; 6] { crate::xlate::test_host(&WINDOWS_limits, &XNU_limits) }
pub static NAMES_limits: [&str; 6] = ["LINK_MAX", "MAX_CANON", "MAX_INPUT", "NGROUPS_MAX", "PIPE_BUF", "SOMAXCONN"];
pub static LINUX_limits: [i64; 6] = [127, 255, 255, 65536, 4096, 4096];
pub static WINDOWS_limits: [i64; 6] = [64, 255, 255, 0, 4096, 2147483647];
pub static XNU_limits: [i64; 6] = [32767, 1024, 1024, 16, 512, 128];
static mut HOST_limits: [i64; 6] = [0; 6];
static STATE_limits: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn limits() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_limits, &LINUX_limits, &STATE_limits, &raw mut HOST_limits, host_limits)
}
// ---- rlimit (enum) ----
#[cfg(not(test))]
unsafe extern "C" {
static RLIMIT_AS: u32;
static RLIMIT_CORE: u32;
static RLIMIT_CPU: u32;
static RLIMIT_DATA: u32;
static RLIMIT_FSIZE: u32;
static RLIMIT_LOCKS: u32;
static RLIMIT_MEMLOCK: u32;
static RLIMIT_MSGQUEUE: u32;
static RLIMIT_NICE: u32;
static RLIMIT_NOFILE: u32;
static RLIMIT_NPROC: u32;
static RLIMIT_NPTS: u32;
static RLIMIT_RSS: u32;
static RLIMIT_RTPRIO: u32;
static RLIMIT_RTTIME: u32;
static RLIMIT_SBSIZE: u32;
static RLIMIT_SIGPENDING: u32;
static RLIMIT_STACK: u32;
static RLIMIT_SWAP: u32;
}
#[cfg(not(test))]
fn host_rlimit() -> [i64; 19] { unsafe { [RLIMIT_AS as i64, RLIMIT_CORE as i64, RLIMIT_CPU as i64, RLIMIT_DATA as i64, RLIMIT_FSIZE as i64, RLIMIT_LOCKS as i64, RLIMIT_MEMLOCK as i64, RLIMIT_MSGQUEUE as i64, RLIMIT_NICE as i64, RLIMIT_NOFILE as i64, RLIMIT_NPROC as i64, RLIMIT_NPTS as i64, RLIMIT_RSS as i64, RLIMIT_RTPRIO as i64, RLIMIT_RTTIME as i64, RLIMIT_SBSIZE as i64, RLIMIT_SIGPENDING as i64, RLIMIT_STACK as i64, RLIMIT_SWAP as i64] } }
#[cfg(test)]
fn host_rlimit() -> [i64; 19] { crate::xlate::test_host(&WINDOWS_rlimit, &XNU_rlimit) }
pub static NAMES_rlimit: [&str; 19] = ["RLIMIT_AS", "RLIMIT_CORE", "RLIMIT_CPU", "RLIMIT_DATA", "RLIMIT_FSIZE", "RLIMIT_LOCKS", "RLIMIT_MEMLOCK", "RLIMIT_MSGQUEUE", "RLIMIT_NICE", "RLIMIT_NOFILE", "RLIMIT_NPROC", "RLIMIT_NPTS", "RLIMIT_RSS", "RLIMIT_RTPRIO", "RLIMIT_RTTIME", "RLIMIT_SBSIZE", "RLIMIT_SIGPENDING", "RLIMIT_STACK", "RLIMIT_SWAP"];
pub static LINUX_rlimit: [i64; 19] = [9, 4, 0, 2, 1, 10, 8, 12, 13, 7, 6, 127, 5, 14, 15, 127, 11, 3, 127];
pub static WINDOWS_rlimit: [i64; 19] = [0, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 1, 127];
pub static XNU_rlimit: [i64; 19] = [5, 4, 0, 2, 1, 127, 6, 127, 127, 8, 7, 127, 5, 127, 127, 127, 127, 3, 127];
static mut HOST_rlimit: [i64; 19] = [0; 19];
static STATE_rlimit: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn rlimit() -> Group {
crate::xlate::group(Kind::Enum, &NAMES_rlimit, &LINUX_rlimit, &STATE_rlimit, &raw mut HOST_rlimit, host_rlimit)
}
// ---- iff (mask) ----
#[cfg(not(test))]
unsafe extern "C" {
static IFF_ALLMULTI: i32;
static IFF_AUTOMEDIA: i32;
static IFF_BROADCAST: i32;
static IFF_DEBUG: i32;
static IFF_DYNAMIC: i32;
static IFF_LOOPBACK: i32;
static IFF_MASTER: i32;
static IFF_MULTICAST: i32;
static IFF_NOARP: i32;
static IFF_NOTRAILERS: i32;
static IFF_POINTOPOINT: i32;
static IFF_PORTSEL: i32;
static IFF_PROMISC: i32;
static IFF_RUNNING: i32;
static IFF_SLAVE: i32;
static IFF_UP: i32;
}
#[cfg(not(test))]
fn host_iff() -> [i64; 16] { unsafe { [IFF_ALLMULTI as i64, IFF_AUTOMEDIA as i64, IFF_BROADCAST as i64, IFF_DEBUG as i64, IFF_DYNAMIC as i64, IFF_LOOPBACK as i64, IFF_MASTER as i64, IFF_MULTICAST as i64, IFF_NOARP as i64, IFF_NOTRAILERS as i64, IFF_POINTOPOINT as i64, IFF_PORTSEL as i64, IFF_PROMISC as i64, IFF_RUNNING as i64, IFF_SLAVE as i64, IFF_UP as i64] } }
#[cfg(test)]
fn host_iff() -> [i64; 16] { crate::xlate::test_host(&WINDOWS_iff, &XNU_iff) }
pub static NAMES_iff: [&str; 16] = ["IFF_ALLMULTI", "IFF_AUTOMEDIA", "IFF_BROADCAST", "IFF_DEBUG", "IFF_DYNAMIC", "IFF_LOOPBACK", "IFF_MASTER", "IFF_MULTICAST", "IFF_NOARP", "IFF_NOTRAILERS", "IFF_POINTOPOINT", "IFF_PORTSEL", "IFF_PROMISC", "IFF_RUNNING", "IFF_SLAVE", "IFF_UP"];
pub static LINUX_iff: [i64; 16] = [512, 16384, 2, 4, 32768, 8, 1024, 4096, 128, 32, 16, 8192, 256, 64, 2048, 1];
pub static WINDOWS_iff: [i64; 16] = [512, 0, 2, 4, 0, 4, 0, 4096, 128, 0, 16, 0, 0, 0, 0, 1];
pub static XNU_iff: [i64; 16] = [512, 0, 2, 4, 0, 8, 0, 32768, 128, 32, 16, 0, 256, 64, 0, 1];
static mut HOST_iff: [i64; 16] = [0; 16];
static STATE_iff: core::sync::atomic::AtomicU8 = core::sync::atomic::AtomicU8::new(0);
pub fn iff() -> Group {
crate::xlate::group(Kind::Mask, &NAMES_iff, &LINUX_iff, &STATE_iff, &raw mut HOST_iff, host_iff)
}
// ---- errno-only wrappers: pass the registers through, fix errno on failure ----
// Sound because every function here takes only integer/pointer arguments (no
// floats, no structs by value), which the SysV and AAPCS conventions pass in the
// first six/eight integer registers regardless of declared type; an untyped
// six-register signature therefore forwards any of them unchanged.
unsafe extern "C" { fn __cosmo_real_chdir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_chdir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_chdir(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_chmod(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_chmod(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_chmod(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_chown(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_chown(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_chown(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_chroot(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_chroot(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_chroot(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_close(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_close(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_close(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_closedir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_closedir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_closedir(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_copy_file_range(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_copy_file_range(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_copy_file_range(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_dirfd(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_dirfd(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_dirfd(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_dup(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_dup(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_dup(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_dup2(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_dup2(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_dup2(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_execvp(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_execvp(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_execvp(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_fchmod(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_fchmod(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_fchmod(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_fchown(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_fchown(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_fchown(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_fdatasync(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_fdatasync(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_fdatasync(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_flock(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_flock(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_flock(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_fork(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_fork(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_fork(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_fsync(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_fsync(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_fsync(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_ftruncate(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_ftruncate(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_ftruncate(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_futimens(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_futimens(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_futimens(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_gethostname(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_gethostname(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_gethostname(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_getrandom(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_getrandom(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_getrandom(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_lchown(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_lchown(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_lchown(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_listen(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_listen(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_listen(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_lseek(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_lseek(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_lseek(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_mkdir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_mkdir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_mkdir(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_mkfifo(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_mkfifo(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_mkfifo(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_munmap(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_munmap(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_munmap(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_pause(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pause(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pause(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_pread(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pread(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pread(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_preadv(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_preadv(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_preadv(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_pwrite(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pwrite(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pwrite(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_pwritev(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pwritev(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pwritev(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_read(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_read(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_read(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_readlink(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_readlink(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_readlink(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_readv(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_readv(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_readv(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_rmdir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_rmdir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_rmdir(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_sched_getaffinity(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_sched_getaffinity(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_sched_getaffinity(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_sendfile(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_sendfile(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_sendfile(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_setgid(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_setgid(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_setgid(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_setgroups(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_setgroups(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_setgroups(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_setpgid(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_setpgid(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_setpgid(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_setsid(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_setsid(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_setsid(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_setuid(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_setuid(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_setuid(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_splice(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_splice(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_splice(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_symlink(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_symlink(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_symlink(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_sysconf(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_sysconf(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_sysconf(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_unlink(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_unlink(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_unlink(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_write(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_write(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_write(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_writev(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_writev(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_writev(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_shutdown(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_shutdown(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_shutdown(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_mprotect(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_mprotect(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_mprotect(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_sigaltstack(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_sigaltstack(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_sigaltstack(a, b, c, d, e, f) };
if r as i32 == -1 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_fdopendir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_fdopendir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_fdopendir(a, b, c, d, e, f) };
if r == 0 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_getcwd(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_getcwd(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_getcwd(a, b, c, d, e, f) };
if r == 0 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_opendir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_opendir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_opendir(a, b, c, d, e, f) };
if r == 0 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_readdir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_readdir(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_readdir(a, b, c, d, e, f) };
if r == 0 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_realpath(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_realpath(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_realpath(a, b, c, d, e, f) };
if r == 0 { crate::shim::fix_errno(); }
r
}
unsafe extern "C" { fn __cosmo_real_getpwuid_r(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_getpwuid_r(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_getpwuid_r(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_posix_spawnattr_destroy(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_posix_spawnattr_destroy(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_posix_spawnattr_destroy(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_posix_spawnattr_init(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_posix_spawnattr_init(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_posix_spawnattr_init(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_posix_spawnattr_setflags(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_posix_spawnattr_setflags(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_posix_spawnattr_setflags(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_posix_spawnattr_setpgroup(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_posix_spawnattr_setpgroup(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_posix_spawnattr_setpgroup(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_posix_spawnattr_setsigdefault(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_posix_spawnattr_setsigdefault(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_posix_spawnattr_setsigdefault(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_posix_spawn_file_actions_addchdir_np(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_posix_spawn_file_actions_addchdir_np(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_posix_spawn_file_actions_addchdir_np(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_posix_spawn_file_actions_adddup2(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_posix_spawn_file_actions_adddup2(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_posix_spawn_file_actions_adddup2(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_posix_spawn_file_actions_destroy(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_posix_spawn_file_actions_destroy(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_posix_spawn_file_actions_destroy(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_posix_spawn_file_actions_init(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_posix_spawn_file_actions_init(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_posix_spawn_file_actions_init(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_posix_spawnp(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_posix_spawnp(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_posix_spawnp(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_attr_destroy(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_attr_destroy(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_attr_destroy(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_attr_getguardsize(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_attr_getguardsize(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_attr_getguardsize(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_attr_getstack(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_attr_getstack(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_attr_getstack(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_attr_init(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_attr_init(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_attr_init(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_attr_setstacksize(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_attr_setstacksize(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_attr_setstacksize(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_create(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_create(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_create(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_detach(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_detach(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_detach(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_getattr_np(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_getattr_np(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_getattr_np(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_join(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_join(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_join(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_key_create(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_key_create(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_key_create(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_key_delete(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_key_delete(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_key_delete(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_setname_np(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_setname_np(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_setname_np(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}
unsafe extern "C" { fn __cosmo_real_pthread_setspecific(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize; }
#[unsafe(no_mangle)]
pub unsafe extern "C" fn __wrap_pthread_setspecific(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> isize {
let r = unsafe { __cosmo_real_pthread_setspecific(a, b, c, d, e, f) };
crate::xlate::errno_to_linux(r as i32 as i64) as isize
}