summaryrefslogtreecommitdiff
path: root/libc/src/unix/haiku/mod.rs
diff options
context:
space:
mode:
authorDaniel Mueller <deso@posteo.net>2018-12-10 21:00:27 -0800
committerDaniel Mueller <deso@posteo.net>2018-12-10 21:00:27 -0800
commite2604a756aaddcd5919ee2f1b9cc0055d200f846 (patch)
tree1ea1b9900db20d3aadbddbce18882d0c957247d7 /libc/src/unix/haiku/mod.rs
parent5875df6c958743cf86c75b2cb5fc2efe5ca0de43 (diff)
downloadnitrocli-e2604a756aaddcd5919ee2f1b9cc0055d200f846.tar.gz
nitrocli-e2604a756aaddcd5919ee2f1b9cc0055d200f846.tar.bz2
Update libc crate to 0.2.45
This change updates the libc crate to version 0.2.45. Import subrepo libc/:libc at f5636fc618f8e16968b3178196d73c94ad9f7b05
Diffstat (limited to 'libc/src/unix/haiku/mod.rs')
-rw-r--r--libc/src/unix/haiku/mod.rs43
1 files changed, 39 insertions, 4 deletions
diff --git a/libc/src/unix/haiku/mod.rs b/libc/src/unix/haiku/mod.rs
index 9b0252d..e65bca7 100644
--- a/libc/src/unix/haiku/mod.rs
+++ b/libc/src/unix/haiku/mod.rs
@@ -351,6 +351,10 @@ pub const F_SETLK: ::c_int = 0x0080;
pub const F_SETLKW: ::c_int = 0x0100;
pub const F_DUPFD_CLOEXEC: ::c_int = 0x0200;
+pub const F_RDLCK: ::c_int = 0x0040;
+pub const F_UNLCK: ::c_int = 0x0200;
+pub const F_WRLCK: ::c_int = 0x0400;
+
pub const AT_FDCWD: ::c_int = -1;
pub const AT_SYMLINK_NOFOLLOW: ::c_int = 0x01;
pub const AT_SYMLINK_FOLLOW: ::c_int = 0x02;
@@ -379,6 +383,7 @@ pub const RLIMIT_CPU: ::c_int = 1;
pub const RLIMIT_DATA: ::c_int = 2;
pub const RLIMIT_FSIZE: ::c_int = 3;
pub const RLIMIT_NOFILE: ::c_int = 4;
+pub const RLIMIT_STACK: ::c_int = 5;
pub const RLIMIT_AS: ::c_int = 6;
// Haiku specific
pub const RLIMIT_NOVMON: ::c_int = 7;
@@ -386,7 +391,7 @@ pub const RLIMIT_NLIMITS: ::c_int = 8;
pub const RUSAGE_SELF: ::c_int = 0;
-pub const RTLD_LAXY: ::c_int = 0;
+pub const RTLD_LAZY: ::c_int = 0;
pub const NCCS: usize = 11;
@@ -645,22 +650,43 @@ pub const AF_UNIX: ::c_int = AF_LOCAL;
pub const AF_BLUETOOTH: ::c_int = 10;
pub const AF_MAX: ::c_int = 11;
+pub const IP_OPTIONS: ::c_int = 1;
+pub const IP_HDRINCL: ::c_int = 2;
+pub const IP_TOS: ::c_int = 3;
+pub const IP_TTL: ::c_int = 4;
+pub const IP_RECVOPTS: ::c_int = 5;
+pub const IP_RECVRETOPTS: ::c_int = 6;
+pub const IP_RECVDSTADDR: ::c_int = 7;
+pub const IP_RETOPTS: ::c_int = 8;
+pub const IP_MULTICAST_IF: ::c_int = 9;
pub const IP_MULTICAST_TTL: ::c_int = 10;
pub const IP_MULTICAST_LOOP: ::c_int = 11;
-pub const IP_TTL: ::c_int = 4;
-pub const IP_HDRINCL: ::c_int = 2;
pub const IP_ADD_MEMBERSHIP: ::c_int = 12;
pub const IP_DROP_MEMBERSHIP: ::c_int = 13;
+pub const IP_BLOCK_SOURCE: ::c_int = 14;
+pub const IP_UNBLOCK_SOURCE: ::c_int = 15;
+pub const IP_ADD_SOURCE_MEMBERSHIP: ::c_int = 16;
+pub const IP_DROP_SOURCE_MEMBERSHIP: ::c_int = 17;
pub const TCP_NODELAY: ::c_int = 0x01;
pub const TCP_MAXSEG: ::c_int = 0x02;
pub const TCP_NOPUSH: ::c_int = 0x04;
pub const TCP_NOOPT: ::c_int = 0x08;
+pub const IPV6_MULTICAST_IF: ::c_int = 24;
+pub const IPV6_MULTICAST_HOPS: ::c_int = 25;
pub const IPV6_MULTICAST_LOOP: ::c_int = 26;
+pub const IPV6_UNICAST_HOPS: ::c_int = 27;
pub const IPV6_JOIN_GROUP: ::c_int = 28;
pub const IPV6_LEAVE_GROUP: ::c_int = 29;
pub const IPV6_V6ONLY: ::c_int = 30;
+pub const IPV6_PKTINFO: ::c_int = 31;
+pub const IPV6_RECVPKTINFO: ::c_int = 32;
+pub const IPV6_HOPLIMIT: ::c_int = 33;
+pub const IPV6_REVCHOPLIMIT: ::c_int = 34;
+pub const IPV6_HOPOPTS: ::c_int = 35;
+pub const IPV6_DSTOPTS: ::c_int = 36;
+pub const IPV6_RTHDR: ::c_int = 37;
pub const MSG_OOB: ::c_int = 0x0001;
pub const MSG_PEEK: ::c_int = 0x0002;
@@ -701,7 +727,9 @@ pub const SA_ONESHOT: ::c_int = SA_RESETHAND;
pub const FD_SETSIZE: usize = 1024;
+pub const RTLD_LOCAL: ::c_int = 0x0;
pub const RTLD_NOW: ::c_int = 0x1;
+pub const RTLD_GLOBAL: ::c_int = 0x2;
pub const RTLD_DEFAULT: *mut ::c_void = 0isize as *mut ::c_void;
pub const BUFSIZ: ::c_uint = 8192;
@@ -1058,6 +1086,14 @@ f! {
}
}
+extern {
+ pub fn abs(i: ::c_int) -> ::c_int;
+ pub fn atof(s: *const ::c_char) -> ::c_double;
+ pub fn labs(i: ::c_long) -> ::c_long;
+ pub fn rand() -> ::c_int;
+ pub fn srand(seed: ::c_uint);
+}
+
#[link(name = "bsd")]
extern {
pub fn clock_gettime(clk_id: ::c_int, tp: *mut ::timespec) -> ::c_int;
@@ -1094,7 +1130,6 @@ extern {
pub fn waitid(idtype: idtype_t, id: id_t, infop: *mut ::siginfo_t,
options: ::c_int) -> ::c_int;
- pub fn fdopendir(fd: ::c_int) -> *mut ::DIR;
pub fn glob(pattern: *const ::c_char,
flags: ::c_int,
errfunc: Option<extern fn(epath: *const ::c_char,