diff options
Diffstat (limited to 'third_party/libc/src/unix/notbsd/linux/other/b64/mod.rs')
-rw-r--r-- | third_party/libc/src/unix/notbsd/linux/other/b64/mod.rs | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/third_party/libc/src/unix/notbsd/linux/other/b64/mod.rs b/third_party/libc/src/unix/notbsd/linux/other/b64/mod.rs new file mode 100644 index 0000000..ccf9988 --- /dev/null +++ b/third_party/libc/src/unix/notbsd/linux/other/b64/mod.rs | |||
@@ -0,0 +1,51 @@ | |||
1 | //! 64-bit specific definitions for linux-like values | ||
2 | |||
3 | pub type c_long = i64; | ||
4 | pub type c_ulong = u64; | ||
5 | pub type clock_t = i64; | ||
6 | pub type time_t = i64; | ||
7 | pub type suseconds_t = i64; | ||
8 | pub type ino_t = u64; | ||
9 | pub type off_t = i64; | ||
10 | pub type blkcnt_t = i64; | ||
11 | pub type __fsword_t = ::c_long; | ||
12 | |||
13 | s! { | ||
14 | pub struct sigset_t { | ||
15 | __val: [::c_ulong; 16], | ||
16 | } | ||
17 | |||
18 | pub struct sysinfo { | ||
19 | pub uptime: ::c_long, | ||
20 | pub loads: [::c_ulong; 3], | ||
21 | pub totalram: ::c_ulong, | ||
22 | pub freeram: ::c_ulong, | ||
23 | pub sharedram: ::c_ulong, | ||
24 | pub bufferram: ::c_ulong, | ||
25 | pub totalswap: ::c_ulong, | ||
26 | pub freeswap: ::c_ulong, | ||
27 | pub procs: ::c_ushort, | ||
28 | pub pad: ::c_ushort, | ||
29 | pub totalhigh: ::c_ulong, | ||
30 | pub freehigh: ::c_ulong, | ||
31 | pub mem_unit: ::c_uint, | ||
32 | pub _f: [::c_char; 0], | ||
33 | } | ||
34 | } | ||
35 | |||
36 | pub const __SIZEOF_PTHREAD_RWLOCK_T: usize = 56; | ||
37 | |||
38 | cfg_if! { | ||
39 | if #[cfg(target_arch = "aarch64")] { | ||
40 | mod aarch64; | ||
41 | pub use self::aarch64::*; | ||
42 | } else if #[cfg(any(target_arch = "powerpc64"))] { | ||
43 | mod powerpc64; | ||
44 | pub use self::powerpc64::*; | ||
45 | } else if #[cfg(any(target_arch = "x86_64"))] { | ||
46 | mod x86_64; | ||
47 | pub use self::x86_64::*; | ||
48 | } else { | ||
49 | // Unknown target_arch | ||
50 | } | ||
51 | } | ||