Auto merge of #902 - gnzlbg:missing_linux_intrinsics, r=malbarbo
Missing linux intrinsics
This commit is contained in:
commit
782794985c
|
@ -99,6 +99,7 @@ fn main() {
|
|||
cfg.header("sys/socket.h");
|
||||
if linux && !musl {
|
||||
cfg.header("linux/if.h");
|
||||
cfg.header("sys/auxv.h");
|
||||
}
|
||||
cfg.header("sys/time.h");
|
||||
cfg.header("sys/un.h");
|
||||
|
|
|
@ -1508,7 +1508,6 @@ extern {
|
|||
nbytes: ::off64_t, flags: ::c_uint) -> ::c_int;
|
||||
pub fn getifaddrs(ifap: *mut *mut ::ifaddrs) -> ::c_int;
|
||||
pub fn freeifaddrs(ifa: *mut ::ifaddrs);
|
||||
|
||||
pub fn mremap(addr: *mut ::c_void,
|
||||
len: ::size_t,
|
||||
new_len: ::size_t,
|
||||
|
@ -1534,7 +1533,8 @@ extern {
|
|||
-> ::c_int;
|
||||
|
||||
pub fn msync(addr: *mut ::c_void, len: ::size_t, flags: ::c_int) -> ::c_int;
|
||||
|
||||
pub fn remap_file_pages(addr: *mut ::c_void, size: ::size_t, prot: ::c_int,
|
||||
pgoff: ::size_t, flags: ::c_int) -> ::c_int;
|
||||
pub fn recvfrom(socket: ::c_int, buf: *mut ::c_void, len: ::size_t,
|
||||
flags: ::c_int, addr: *mut ::sockaddr,
|
||||
addrlen: *mut ::socklen_t) -> ::ssize_t;
|
||||
|
|
|
@ -165,6 +165,19 @@ s! {
|
|||
__size: [::c_char; 32],
|
||||
__align: [::c_long; 0],
|
||||
}
|
||||
|
||||
pub struct mallinfo {
|
||||
pub arena: ::c_int,
|
||||
pub ordblks: ::c_int,
|
||||
pub smblks: ::c_int,
|
||||
pub hblks: ::c_int,
|
||||
pub hblkhd: ::c_int,
|
||||
pub usmblks: ::c_int,
|
||||
pub fsmblks: ::c_int,
|
||||
pub uordblks: ::c_int,
|
||||
pub fordblks: ::c_int,
|
||||
pub keepcost: ::c_int,
|
||||
}
|
||||
}
|
||||
|
||||
pub const __UT_LINESIZE: usize = 32;
|
||||
|
@ -674,6 +687,9 @@ extern {
|
|||
pub fn pthread_rwlockattr_setkind_np(attr: *mut ::pthread_rwlockattr_t,
|
||||
val: ::c_int) -> ::c_int;
|
||||
pub fn sched_getcpu() -> ::c_int;
|
||||
pub fn mallinfo() -> ::mallinfo;
|
||||
pub fn malloc_usable_size(ptr: *mut ::c_void) -> ::size_t;
|
||||
pub fn getauxval(type_: ::c_ulong) -> ::c_ulong;
|
||||
}
|
||||
|
||||
cfg_if! {
|
||||
|
|
Loading…
Reference in New Issue