diff options
author | Baoshan <pangbw@gmail.com> | 2019-09-24 13:40:28 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-09-24 13:40:28 -0700 |
commit | a195fd4ac69622e74b759ec374956d7332ff8422 (patch) | |
tree | c4da8d715e8b24c4e8486943eab8e989cc894048 /src/unix/bsd/freebsdlike/freebsd/x86_64/mod.rs | |
parent | 7f753ce510cb9a920d44d0c447f705f03473edc3 (diff) | |
parent | 90269e85baa534679ca0c29348a83c1918925a72 (diff) | |
download | rust-libc-a195fd4ac69622e74b759ec374956d7332ff8422.tar.gz |
Merge pull request #17 from rust-lang/master
Sync to rust-lang/libc branch master
Diffstat (limited to 'src/unix/bsd/freebsdlike/freebsd/x86_64/mod.rs')
-rw-r--r-- | src/unix/bsd/freebsdlike/freebsd/x86_64/mod.rs | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/unix/bsd/freebsdlike/freebsd/x86_64/mod.rs b/src/unix/bsd/freebsdlike/freebsd/x86_64/mod.rs new file mode 100644 index 0000000000..0769a22f88 --- /dev/null +++ b/src/unix/bsd/freebsdlike/freebsd/x86_64/mod.rs @@ -0,0 +1,24 @@ +pub type c_char = i8; +pub type c_long = i64; +pub type c_ulong = u64; +pub type time_t = i64; +pub type suseconds_t = i64; + +// should be pub(crate), but that requires Rust 1.18.0 +cfg_if! { + if #[cfg(libc_const_size_of)] { + #[doc(hidden)] + pub const _ALIGNBYTES: usize = ::mem::size_of::<::c_long>() - 1; + } else { + #[doc(hidden)] + pub const _ALIGNBYTES: usize = 8 - 1; + } +} +pub const MAP_32BIT: ::c_int = 0x00080000; + +cfg_if! { + if #[cfg(libc_align)] { + mod align; + pub use self::align::*; + } +} |