Skip to content

Commit

Permalink
Fix test suite on FreeBSD 11
Browse files Browse the repository at this point in the history
  • Loading branch information
wezm committed Mar 12, 2018
1 parent 787420a commit be2f062
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
1 change: 1 addition & 0 deletions libc-test/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -509,6 +509,7 @@ fn main() {
"CTL_MAXID" |
"KERN_MAXID" |
"HW_MAXID" |
"NET_MAXID" |
"USER_MAXID" if freebsd => true,

// These constants were added in FreeBSD 11
Expand Down
14 changes: 8 additions & 6 deletions src/unix/bsd/freebsdlike/freebsd/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ pub type clock_t = i32;
pub type ino_t = u32;
pub type lwpid_t = i32;
pub type nlink_t = u16;
pub type blksize_t = u32;
pub type blksize_t = i32;
pub type clockid_t = ::c_int;
pub type sem_t = _sem;

Expand Down Expand Up @@ -182,7 +182,9 @@ pub const EOWNERDEAD: ::c_int = 96;
pub const ELAST: ::c_int = 96;
pub const RLIMIT_NPTS: ::c_int = 11;
pub const RLIMIT_SWAP: ::c_int = 12;
pub const RLIM_NLIMITS: ::rlim_t = 13;
pub const RLIMIT_KQUEUES: ::c_int = 13;
pub const RLIMIT_UMTXP: ::c_int = 14;
pub const RLIM_NLIMITS: ::rlim_t = 15;

pub const Q_GETQUOTA: ::c_int = 0x700;
pub const Q_SETQUOTA: ::c_int = 0x800;
Expand Down Expand Up @@ -801,10 +803,10 @@ pub const SHUTDOWN_TIME: ::c_short = 8;

pub const LC_COLLATE_MASK: ::c_int = (1 << 0);
pub const LC_CTYPE_MASK: ::c_int = (1 << 1);
pub const LC_MESSAGES_MASK: ::c_int = (1 << 2);
pub const LC_MONETARY_MASK: ::c_int = (1 << 3);
pub const LC_NUMERIC_MASK: ::c_int = (1 << 4);
pub const LC_TIME_MASK: ::c_int = (1 << 5);
pub const LC_MONETARY_MASK: ::c_int =(1 << 2);
pub const LC_NUMERIC_MASK: ::c_int = (1 << 3);
pub const LC_TIME_MASK: ::c_int = (1 << 4);
pub const LC_MESSAGES_MASK: ::c_int = (1 << 5);
pub const LC_ALL_MASK: ::c_int = LC_COLLATE_MASK
| LC_CTYPE_MASK
| LC_MESSAGES_MASK
Expand Down

0 comments on commit be2f062

Please sign in to comment.