2 pub type pthread_attr_t
= *mut ::c_void
;
4 pub type pthread_mutex_t
= *mut ::c_void
;
5 pub type pthread_mutexattr_t
= *mut ::c_void
;
6 pub type pthread_cond_t
= *mut ::c_void
;
7 pub type pthread_condattr_t
= *mut ::c_void
;
8 pub type pthread_rwlock_t
= *mut ::c_void
;
9 pub type pthread_rwlockattr_t
= *mut ::c_void
;
10 pub type pthread_key_t
= ::c_int
;
11 pub type tcflag_t
= ::c_uint
;
12 pub type speed_t
= ::c_uint
;
13 pub type nl_item
= ::c_int
;
15 pub type vm_size_t
= ::uintptr_t
;
16 pub type key_t
= ::c_long
;
20 pub type Elf32_Addr
= u32;
21 pub type Elf32_Half
= u16;
22 pub type Elf32_Lword
= u64;
23 pub type Elf32_Off
= u32;
24 pub type Elf32_Sword
= i32;
25 pub type Elf32_Word
= u32;
27 pub type Elf64_Addr
= u64;
28 pub type Elf64_Half
= u16;
29 pub type Elf64_Lword
= u64;
30 pub type Elf64_Off
= u64;
31 pub type Elf64_Sword
= i32;
32 pub type Elf64_Sxword
= i64;
33 pub type Elf64_Word
= u32;
34 pub type Elf64_Xword
= u64;
36 pub type iconv_t
= *mut ::c_void
;
39 if #[cfg(target_pointer_width = "64")] {
40 type Elf_Addr
= Elf64_Addr
;
41 type Elf_Half
= Elf64_Half
;
42 type Elf_Phdr
= Elf64_Phdr
;
43 } else if #[cfg(target_pointer_width = "32")] {
44 type Elf_Addr
= Elf32_Addr
;
45 type Elf_Half
= Elf32_Half
;
46 type Elf_Phdr
= Elf32_Phdr
;
52 #[cfg_attr(feature = "extra_traits", derive(Debug))]
54 impl ::Copy
for timezone {}
55 impl ::Clone
for timezone
{
56 fn clone(&self) -> timezone
{
62 pub unsafe fn si_addr(&self) -> *mut ::c_void
{
66 pub unsafe fn si_value(&self) -> ::sigval
{
70 pub unsafe fn si_pid(&self) -> ::pid_t
{
74 pub unsafe fn si_uid(&self) -> ::uid_t
{
78 pub unsafe fn si_status(&self) -> ::c_int
{
85 pub s_addr
: ::in_addr_t
,
89 pub imr_multiaddr
: in_addr
,
90 pub imr_interface
: in_addr
,
94 pub imr_multiaddr
: in_addr
,
95 pub imr_address
: in_addr
,
96 pub imr_ifindex
: ::c_int
,
100 pub gl_pathc
: ::size_t
,
101 pub gl_matchc
: ::size_t
,
102 pub gl_offs
: ::size_t
,
103 pub gl_flags
: ::c_int
,
104 pub gl_pathv
: *mut *mut ::c_char
,
105 __unused3
: *mut ::c_void
,
106 __unused4
: *mut ::c_void
,
107 __unused5
: *mut ::c_void
,
108 __unused6
: *mut ::c_void
,
109 __unused7
: *mut ::c_void
,
110 __unused8
: *mut ::c_void
,
113 pub struct addrinfo
{
114 pub ai_flags
: ::c_int
,
115 pub ai_family
: ::c_int
,
116 pub ai_socktype
: ::c_int
,
117 pub ai_protocol
: ::c_int
,
118 pub ai_addrlen
: ::socklen_t
,
119 pub ai_canonname
: *mut ::c_char
,
120 pub ai_addr
: *mut ::sockaddr
,
121 pub ai_next
: *mut addrinfo
,
124 pub struct sigset_t
{
128 pub struct siginfo_t
{
129 pub si_signo
: ::c_int
,
130 pub si_errno
: ::c_int
,
131 pub si_code
: ::c_int
,
134 pub si_status
: ::c_int
,
135 pub si_addr
: *mut ::c_void
,
136 pub si_value
: ::sigval
,
141 pub struct sigaction
{
142 pub sa_sigaction
: ::sighandler_t
,
143 pub sa_flags
: ::c_int
,
144 pub sa_mask
: sigset_t
,
147 pub struct sched_param
{
148 pub sched_priority
: ::c_int
,
152 pub dli_fname
: *const ::c_char
,
153 pub dli_fbase
: *mut ::c_void
,
154 pub dli_sname
: *const ::c_char
,
155 pub dli_saddr
: *mut ::c_void
,
158 pub struct sockaddr_in
{
160 pub sin_family
: ::sa_family_t
,
161 pub sin_port
: ::in_port_t
,
162 pub sin_addr
: ::in_addr
,
163 pub sin_zero
: [::c_char
; 8],
167 pub c_iflag
: ::tcflag_t
,
168 pub c_oflag
: ::tcflag_t
,
169 pub c_cflag
: ::tcflag_t
,
170 pub c_lflag
: ::tcflag_t
,
171 pub c_cc
: [::cc_t
; ::NCCS
],
172 pub c_ispeed
: ::speed_t
,
173 pub c_ospeed
: ::speed_t
,
177 pub l_start
: ::off_t
,
180 pub l_type
: ::c_short
,
181 pub l_whence
: ::c_short
,
182 #[cfg(not(target_os = "dragonfly"))]
183 pub l_sysid
: ::c_int
,
187 pub headers
: *mut ::iovec
,
188 pub hdr_cnt
: ::c_int
,
189 pub trailers
: *mut ::iovec
,
190 pub trl_cnt
: ::c_int
,
194 pub decimal_point
: *mut ::c_char
,
195 pub thousands_sep
: *mut ::c_char
,
196 pub grouping
: *mut ::c_char
,
197 pub int_curr_symbol
: *mut ::c_char
,
198 pub currency_symbol
: *mut ::c_char
,
199 pub mon_decimal_point
: *mut ::c_char
,
200 pub mon_thousands_sep
: *mut ::c_char
,
201 pub mon_grouping
: *mut ::c_char
,
202 pub positive_sign
: *mut ::c_char
,
203 pub negative_sign
: *mut ::c_char
,
204 pub int_frac_digits
: ::c_char
,
205 pub frac_digits
: ::c_char
,
206 pub p_cs_precedes
: ::c_char
,
207 pub p_sep_by_space
: ::c_char
,
208 pub n_cs_precedes
: ::c_char
,
209 pub n_sep_by_space
: ::c_char
,
210 pub p_sign_posn
: ::c_char
,
211 pub n_sign_posn
: ::c_char
,
212 pub int_p_cs_precedes
: ::c_char
,
213 pub int_n_cs_precedes
: ::c_char
,
214 pub int_p_sep_by_space
: ::c_char
,
215 pub int_n_sep_by_space
: ::c_char
,
216 pub int_p_sign_posn
: ::c_char
,
217 pub int_n_sign_posn
: ::c_char
,
220 pub struct cmsgcred
{
221 pub cmcred_pid
: ::pid_t
,
222 pub cmcred_uid
: ::uid_t
,
223 pub cmcred_euid
: ::uid_t
,
224 pub cmcred_gid
: ::gid_t
,
225 pub cmcred_ngroups
: ::c_short
,
226 pub cmcred_groups
: [::gid_t
; CMGROUP_MAX
],
230 pub type_
: ::c_ushort
,
231 pub prio
: ::c_ushort
,
234 pub struct in6_pktinfo
{
235 pub ipi6_addr
: ::in6_addr
,
236 pub ipi6_ifindex
: ::c_uint
,
249 pub offset
: ::c_long
,
251 pub maxerror
: ::c_long
,
252 pub esterror
: ::c_long
,
254 pub constant
: ::c_long
,
255 pub precision
: ::c_long
,
256 pub tolerance
: ::c_long
,
257 pub ppsfreq
: ::c_long
,
258 pub jitter
: ::c_long
,
260 pub stabil
: ::c_long
,
261 pub jitcnt
: ::c_long
,
262 pub calcnt
: ::c_long
,
263 pub errcnt
: ::c_long
,
264 pub stbcnt
: ::c_long
,
267 pub struct ntptimeval
{
268 pub time
: ::timespec
,
269 pub maxerror
: ::c_long
,
270 pub esterror
: ::c_long
,
272 pub time_state
: ::c_int
,
275 pub struct accept_filter_arg
{
276 pub af_name
: [::c_char
; 16],
277 af_arg
: [[::c_char
; 10]; 24],
280 pub struct ptrace_io_desc
{
281 pub piod_op
: ::c_int
,
282 pub piod_offs
: *mut ::c_void
,
283 pub piod_addr
: *mut ::c_void
,
284 pub piod_len
: ::size_t
,
289 pub struct bpf_program
{
290 pub bf_len
: ::c_uint
,
291 pub bf_insns
: *mut bpf_insn
,
294 pub struct bpf_stat
{
295 pub bs_recv
: ::c_uint
,
296 pub bs_drop
: ::c_uint
,
299 pub struct bpf_version
{
300 pub bv_major
: ::c_ushort
,
301 pub bv_minor
: ::c_ushort
,
305 pub bh_tstamp
: ::timeval
,
308 pub bh_hdrlen
: ::c_ushort
,
311 pub struct bpf_insn
{
312 pub code
: ::c_ushort
,
318 pub struct bpf_dltlist
{
320 bfl_list
: *mut ::c_uint
,
325 pub struct Elf32_Phdr
{
326 pub p_type
: Elf32_Word
,
327 pub p_offset
: Elf32_Off
,
328 pub p_vaddr
: Elf32_Addr
,
329 pub p_paddr
: Elf32_Addr
,
330 pub p_filesz
: Elf32_Word
,
331 pub p_memsz
: Elf32_Word
,
332 pub p_flags
: Elf32_Word
,
333 pub p_align
: Elf32_Word
,
336 pub struct Elf64_Phdr
{
337 pub p_type
: Elf64_Word
,
338 pub p_flags
: Elf64_Word
,
339 pub p_offset
: Elf64_Off
,
340 pub p_vaddr
: Elf64_Addr
,
341 pub p_paddr
: Elf64_Addr
,
342 pub p_filesz
: Elf64_Xword
,
343 pub p_memsz
: Elf64_Xword
,
344 pub p_align
: Elf64_Xword
,
349 pub struct dl_phdr_info
{
350 pub dlpi_addr
: Elf_Addr
,
351 pub dlpi_name
: *const ::c_char
,
352 pub dlpi_phdr
: *const Elf_Phdr
,
353 pub dlpi_phnum
: Elf_Half
,
354 pub dlpi_adds
: ::c_ulonglong
,
355 pub dlpi_subs
: ::c_ulonglong
,
356 pub dlpi_tls_modid
: usize,
357 pub dlpi_tls_data
: *mut ::c_void
,
360 pub struct ipc_perm
{
372 pub struct sockaddr_storage
{
374 pub ss_family
: ::sa_family_t
,
377 __ss_pad2
: [u8; 112],
382 if #[cfg(feature = "extra_traits")] {
383 impl PartialEq
for sockaddr_storage
{
384 fn eq(&self, other
: &sockaddr_storage
) -> bool
{
385 self.ss_len
== other
.ss_len
386 && self.ss_family
== other
.ss_family
387 && self.__ss_pad1
== other
.__ss_pad1
388 && self.__ss_align
== other
.__ss_align
392 .zip(other
.__ss_pad2
.iter())
393 .all(|(a
, b
)| a
== b
)
396 impl Eq
for sockaddr_storage {}
397 impl ::fmt
::Debug
for sockaddr_storage
{
398 fn fmt(&self, f
: &mut ::fmt
::Formatter
) -> ::fmt
::Result
{
399 f
.debug_struct("sockaddr_storage")
400 .field("ss_len", &self.ss_len
)
401 .field("ss_family", &self.ss_family
)
402 .field("__ss_pad1", &self.__ss_pad1
)
403 .field("__ss_align", &self.__ss_align
)
404 // FIXME: .field("__ss_pad2", &self.__ss_pad2)
408 impl ::hash
::Hash
for sockaddr_storage
{
409 fn hash
<H
: ::hash
::Hasher
>(&self, state
: &mut H
) {
410 self.ss_len
.hash(state
);
411 self.ss_family
.hash(state
);
412 self.__ss_pad1
.hash(state
);
413 self.__ss_align
.hash(state
);
414 self.__ss_pad2
.hash(state
);
420 // Non-public helper constant
422 if #[cfg(all(not(libc_const_size_of), target_pointer_width = "32"))] {
423 const SIZEOF_LONG
: usize = 4;
424 } else if #[cfg(all(not(libc_const_size_of), target_pointer_width = "64"))] {
425 const SIZEOF_LONG
: usize = 8;
426 } else if #[cfg(libc_const_size_of)] {
427 const SIZEOF_LONG
: usize = ::mem
::size_of
::<::c_long
>();
433 note
= "Can vary at runtime. Use sysconf(3) instead"
435 pub const AIO_LISTIO_MAX
: ::c_int
= 16;
436 pub const AIO_CANCELED
: ::c_int
= 1;
437 pub const AIO_NOTCANCELED
: ::c_int
= 2;
438 pub const AIO_ALLDONE
: ::c_int
= 3;
439 pub const LIO_NOP
: ::c_int
= 0;
440 pub const LIO_WRITE
: ::c_int
= 1;
441 pub const LIO_READ
: ::c_int
= 2;
442 pub const LIO_WAIT
: ::c_int
= 1;
443 pub const LIO_NOWAIT
: ::c_int
= 0;
445 pub const SIGEV_NONE
: ::c_int
= 0;
446 pub const SIGEV_SIGNAL
: ::c_int
= 1;
447 pub const SIGEV_THREAD
: ::c_int
= 2;
448 pub const SIGEV_KEVENT
: ::c_int
= 3;
450 pub const CODESET
: ::nl_item
= 0;
451 pub const D_T_FMT
: ::nl_item
= 1;
452 pub const D_FMT
: ::nl_item
= 2;
453 pub const T_FMT
: ::nl_item
= 3;
454 pub const T_FMT_AMPM
: ::nl_item
= 4;
455 pub const AM_STR
: ::nl_item
= 5;
456 pub const PM_STR
: ::nl_item
= 6;
458 pub const DAY_1
: ::nl_item
= 7;
459 pub const DAY_2
: ::nl_item
= 8;
460 pub const DAY_3
: ::nl_item
= 9;
461 pub const DAY_4
: ::nl_item
= 10;
462 pub const DAY_5
: ::nl_item
= 11;
463 pub const DAY_6
: ::nl_item
= 12;
464 pub const DAY_7
: ::nl_item
= 13;
466 pub const ABDAY_1
: ::nl_item
= 14;
467 pub const ABDAY_2
: ::nl_item
= 15;
468 pub const ABDAY_3
: ::nl_item
= 16;
469 pub const ABDAY_4
: ::nl_item
= 17;
470 pub const ABDAY_5
: ::nl_item
= 18;
471 pub const ABDAY_6
: ::nl_item
= 19;
472 pub const ABDAY_7
: ::nl_item
= 20;
474 pub const MON_1
: ::nl_item
= 21;
475 pub const MON_2
: ::nl_item
= 22;
476 pub const MON_3
: ::nl_item
= 23;
477 pub const MON_4
: ::nl_item
= 24;
478 pub const MON_5
: ::nl_item
= 25;
479 pub const MON_6
: ::nl_item
= 26;
480 pub const MON_7
: ::nl_item
= 27;
481 pub const MON_8
: ::nl_item
= 28;
482 pub const MON_9
: ::nl_item
= 29;
483 pub const MON_10
: ::nl_item
= 30;
484 pub const MON_11
: ::nl_item
= 31;
485 pub const MON_12
: ::nl_item
= 32;
487 pub const ABMON_1
: ::nl_item
= 33;
488 pub const ABMON_2
: ::nl_item
= 34;
489 pub const ABMON_3
: ::nl_item
= 35;
490 pub const ABMON_4
: ::nl_item
= 36;
491 pub const ABMON_5
: ::nl_item
= 37;
492 pub const ABMON_6
: ::nl_item
= 38;
493 pub const ABMON_7
: ::nl_item
= 39;
494 pub const ABMON_8
: ::nl_item
= 40;
495 pub const ABMON_9
: ::nl_item
= 41;
496 pub const ABMON_10
: ::nl_item
= 42;
497 pub const ABMON_11
: ::nl_item
= 43;
498 pub const ABMON_12
: ::nl_item
= 44;
500 pub const ERA
: ::nl_item
= 45;
501 pub const ERA_D_FMT
: ::nl_item
= 46;
502 pub const ERA_D_T_FMT
: ::nl_item
= 47;
503 pub const ERA_T_FMT
: ::nl_item
= 48;
504 pub const ALT_DIGITS
: ::nl_item
= 49;
506 pub const RADIXCHAR
: ::nl_item
= 50;
507 pub const THOUSEP
: ::nl_item
= 51;
509 pub const YESEXPR
: ::nl_item
= 52;
510 pub const NOEXPR
: ::nl_item
= 53;
512 pub const YESSTR
: ::nl_item
= 54;
513 pub const NOSTR
: ::nl_item
= 55;
515 pub const CRNCYSTR
: ::nl_item
= 56;
517 pub const D_MD_ORDER
: ::nl_item
= 57;
519 pub const ALTMON_1
: ::nl_item
= 58;
520 pub const ALTMON_2
: ::nl_item
= 59;
521 pub const ALTMON_3
: ::nl_item
= 60;
522 pub const ALTMON_4
: ::nl_item
= 61;
523 pub const ALTMON_5
: ::nl_item
= 62;
524 pub const ALTMON_6
: ::nl_item
= 63;
525 pub const ALTMON_7
: ::nl_item
= 64;
526 pub const ALTMON_8
: ::nl_item
= 65;
527 pub const ALTMON_9
: ::nl_item
= 66;
528 pub const ALTMON_10
: ::nl_item
= 67;
529 pub const ALTMON_11
: ::nl_item
= 68;
530 pub const ALTMON_12
: ::nl_item
= 69;
532 pub const EXIT_FAILURE
: ::c_int
= 1;
533 pub const EXIT_SUCCESS
: ::c_int
= 0;
534 pub const EOF
: ::c_int
= -1;
535 pub const SEEK_SET
: ::c_int
= 0;
536 pub const SEEK_CUR
: ::c_int
= 1;
537 pub const SEEK_END
: ::c_int
= 2;
538 pub const SEEK_DATA
: ::c_int
= 3;
539 pub const SEEK_HOLE
: ::c_int
= 4;
540 pub const _IOFBF
: ::c_int
= 0;
541 pub const _IONBF
: ::c_int
= 2;
542 pub const _IOLBF
: ::c_int
= 1;
543 pub const BUFSIZ
: ::c_uint
= 1024;
544 pub const FOPEN_MAX
: ::c_uint
= 20;
545 pub const FILENAME_MAX
: ::c_uint
= 1024;
546 pub const L_tmpnam
: ::c_uint
= 1024;
547 pub const TMP_MAX
: ::c_uint
= 308915776;
549 pub const O_NOCTTY
: ::c_int
= 32768;
550 pub const O_DIRECT
: ::c_int
= 0x00010000;
552 pub const S_IFIFO
: mode_t
= 4096;
553 pub const S_IFCHR
: mode_t
= 8192;
554 pub const S_IFBLK
: mode_t
= 24576;
555 pub const S_IFDIR
: mode_t
= 16384;
556 pub const S_IFREG
: mode_t
= 32768;
557 pub const S_IFLNK
: mode_t
= 40960;
558 pub const S_IFSOCK
: mode_t
= 49152;
559 pub const S_IFMT
: mode_t
= 61440;
560 pub const S_IEXEC
: mode_t
= 64;
561 pub const S_IWRITE
: mode_t
= 128;
562 pub const S_IREAD
: mode_t
= 256;
563 pub const S_IRWXU
: mode_t
= 448;
564 pub const S_IXUSR
: mode_t
= 64;
565 pub const S_IWUSR
: mode_t
= 128;
566 pub const S_IRUSR
: mode_t
= 256;
567 pub const S_IRWXG
: mode_t
= 56;
568 pub const S_IXGRP
: mode_t
= 8;
569 pub const S_IWGRP
: mode_t
= 16;
570 pub const S_IRGRP
: mode_t
= 32;
571 pub const S_IRWXO
: mode_t
= 7;
572 pub const S_IXOTH
: mode_t
= 1;
573 pub const S_IWOTH
: mode_t
= 2;
574 pub const S_IROTH
: mode_t
= 4;
575 pub const F_OK
: ::c_int
= 0;
576 pub const R_OK
: ::c_int
= 4;
577 pub const W_OK
: ::c_int
= 2;
578 pub const X_OK
: ::c_int
= 1;
579 pub const STDIN_FILENO
: ::c_int
= 0;
580 pub const STDOUT_FILENO
: ::c_int
= 1;
581 pub const STDERR_FILENO
: ::c_int
= 2;
582 pub const F_LOCK
: ::c_int
= 1;
583 pub const F_TEST
: ::c_int
= 3;
584 pub const F_TLOCK
: ::c_int
= 2;
585 pub const F_ULOCK
: ::c_int
= 0;
586 pub const F_DUPFD_CLOEXEC
: ::c_int
= 17;
587 pub const F_DUP2FD
: ::c_int
= 10;
588 pub const F_DUP2FD_CLOEXEC
: ::c_int
= 18;
589 pub const SIGHUP
: ::c_int
= 1;
590 pub const SIGINT
: ::c_int
= 2;
591 pub const SIGQUIT
: ::c_int
= 3;
592 pub const SIGILL
: ::c_int
= 4;
593 pub const SIGABRT
: ::c_int
= 6;
594 pub const SIGEMT
: ::c_int
= 7;
595 pub const SIGFPE
: ::c_int
= 8;
596 pub const SIGKILL
: ::c_int
= 9;
597 pub const SIGSEGV
: ::c_int
= 11;
598 pub const SIGPIPE
: ::c_int
= 13;
599 pub const SIGALRM
: ::c_int
= 14;
600 pub const SIGTERM
: ::c_int
= 15;
602 pub const PROT_NONE
: ::c_int
= 0;
603 pub const PROT_READ
: ::c_int
= 1;
604 pub const PROT_WRITE
: ::c_int
= 2;
605 pub const PROT_EXEC
: ::c_int
= 4;
607 pub const MAP_FILE
: ::c_int
= 0x0000;
608 pub const MAP_SHARED
: ::c_int
= 0x0001;
609 pub const MAP_PRIVATE
: ::c_int
= 0x0002;
610 pub const MAP_FIXED
: ::c_int
= 0x0010;
611 pub const MAP_ANON
: ::c_int
= 0x1000;
612 pub const MAP_ANONYMOUS
: ::c_int
= MAP_ANON
;
614 pub const MAP_FAILED
: *mut ::c_void
= !0 as *mut ::c_void
;
616 pub const MCL_CURRENT
: ::c_int
= 0x0001;
617 pub const MCL_FUTURE
: ::c_int
= 0x0002;
619 pub const MNT_NOATIME
: ::c_int
= 0x10000000;
620 pub const MNT_NOCLUSTERR
: ::c_int
= 0x40000000;
621 pub const MNT_NOCLUSTERW
: ::c_int
= 0x80000000;
622 pub const MNT_NOSYMFOLLOW
: ::c_int
= 0x00400000;
623 pub const MNT_SOFTDEP
: ::c_int
= 0x00200000;
624 pub const MNT_SUIDDIR
: ::c_int
= 0x00100000;
625 pub const MNT_EXRDONLY
: ::c_int
= 0x00000080;
626 pub const MNT_DEFEXPORTED
: ::c_int
= 0x00000200;
627 pub const MNT_EXPORTANON
: ::c_int
= 0x00000400;
628 pub const MNT_EXKERB
: ::c_int
= 0x00000800;
629 pub const MNT_DELEXPORT
: ::c_int
= 0x00020000;
631 pub const MS_SYNC
: ::c_int
= 0x0000;
632 pub const MS_ASYNC
: ::c_int
= 0x0001;
633 pub const MS_INVALIDATE
: ::c_int
= 0x0002;
635 pub const EPERM
: ::c_int
= 1;
636 pub const ENOENT
: ::c_int
= 2;
637 pub const ESRCH
: ::c_int
= 3;
638 pub const EINTR
: ::c_int
= 4;
639 pub const EIO
: ::c_int
= 5;
640 pub const ENXIO
: ::c_int
= 6;
641 pub const E2BIG
: ::c_int
= 7;
642 pub const ENOEXEC
: ::c_int
= 8;
643 pub const EBADF
: ::c_int
= 9;
644 pub const ECHILD
: ::c_int
= 10;
645 pub const EDEADLK
: ::c_int
= 11;
646 pub const ENOMEM
: ::c_int
= 12;
647 pub const EACCES
: ::c_int
= 13;
648 pub const EFAULT
: ::c_int
= 14;
649 pub const ENOTBLK
: ::c_int
= 15;
650 pub const EBUSY
: ::c_int
= 16;
651 pub const EEXIST
: ::c_int
= 17;
652 pub const EXDEV
: ::c_int
= 18;
653 pub const ENODEV
: ::c_int
= 19;
654 pub const ENOTDIR
: ::c_int
= 20;
655 pub const EISDIR
: ::c_int
= 21;
656 pub const EINVAL
: ::c_int
= 22;
657 pub const ENFILE
: ::c_int
= 23;
658 pub const EMFILE
: ::c_int
= 24;
659 pub const ENOTTY
: ::c_int
= 25;
660 pub const ETXTBSY
: ::c_int
= 26;
661 pub const EFBIG
: ::c_int
= 27;
662 pub const ENOSPC
: ::c_int
= 28;
663 pub const ESPIPE
: ::c_int
= 29;
664 pub const EROFS
: ::c_int
= 30;
665 pub const EMLINK
: ::c_int
= 31;
666 pub const EPIPE
: ::c_int
= 32;
667 pub const EDOM
: ::c_int
= 33;
668 pub const ERANGE
: ::c_int
= 34;
669 pub const EAGAIN
: ::c_int
= 35;
670 pub const EWOULDBLOCK
: ::c_int
= 35;
671 pub const EINPROGRESS
: ::c_int
= 36;
672 pub const EALREADY
: ::c_int
= 37;
673 pub const ENOTSOCK
: ::c_int
= 38;
674 pub const EDESTADDRREQ
: ::c_int
= 39;
675 pub const EMSGSIZE
: ::c_int
= 40;
676 pub const EPROTOTYPE
: ::c_int
= 41;
677 pub const ENOPROTOOPT
: ::c_int
= 42;
678 pub const EPROTONOSUPPORT
: ::c_int
= 43;
679 pub const ESOCKTNOSUPPORT
: ::c_int
= 44;
680 pub const EOPNOTSUPP
: ::c_int
= 45;
681 pub const ENOTSUP
: ::c_int
= EOPNOTSUPP
;
682 pub const EPFNOSUPPORT
: ::c_int
= 46;
683 pub const EAFNOSUPPORT
: ::c_int
= 47;
684 pub const EADDRINUSE
: ::c_int
= 48;
685 pub const EADDRNOTAVAIL
: ::c_int
= 49;
686 pub const ENETDOWN
: ::c_int
= 50;
687 pub const ENETUNREACH
: ::c_int
= 51;
688 pub const ENETRESET
: ::c_int
= 52;
689 pub const ECONNABORTED
: ::c_int
= 53;
690 pub const ECONNRESET
: ::c_int
= 54;
691 pub const ENOBUFS
: ::c_int
= 55;
692 pub const EISCONN
: ::c_int
= 56;
693 pub const ENOTCONN
: ::c_int
= 57;
694 pub const ESHUTDOWN
: ::c_int
= 58;
695 pub const ETOOMANYREFS
: ::c_int
= 59;
696 pub const ETIMEDOUT
: ::c_int
= 60;
697 pub const ECONNREFUSED
: ::c_int
= 61;
698 pub const ELOOP
: ::c_int
= 62;
699 pub const ENAMETOOLONG
: ::c_int
= 63;
700 pub const EHOSTDOWN
: ::c_int
= 64;
701 pub const EHOSTUNREACH
: ::c_int
= 65;
702 pub const ENOTEMPTY
: ::c_int
= 66;
703 pub const EPROCLIM
: ::c_int
= 67;
704 pub const EUSERS
: ::c_int
= 68;
705 pub const EDQUOT
: ::c_int
= 69;
706 pub const ESTALE
: ::c_int
= 70;
707 pub const EREMOTE
: ::c_int
= 71;
708 pub const EBADRPC
: ::c_int
= 72;
709 pub const ERPCMISMATCH
: ::c_int
= 73;
710 pub const EPROGUNAVAIL
: ::c_int
= 74;
711 pub const EPROGMISMATCH
: ::c_int
= 75;
712 pub const EPROCUNAVAIL
: ::c_int
= 76;
713 pub const ENOLCK
: ::c_int
= 77;
714 pub const ENOSYS
: ::c_int
= 78;
715 pub const EFTYPE
: ::c_int
= 79;
716 pub const EAUTH
: ::c_int
= 80;
717 pub const ENEEDAUTH
: ::c_int
= 81;
718 pub const EIDRM
: ::c_int
= 82;
719 pub const ENOMSG
: ::c_int
= 83;
720 pub const EOVERFLOW
: ::c_int
= 84;
721 pub const ECANCELED
: ::c_int
= 85;
722 pub const EILSEQ
: ::c_int
= 86;
723 pub const ENOATTR
: ::c_int
= 87;
724 pub const EDOOFUS
: ::c_int
= 88;
725 pub const EBADMSG
: ::c_int
= 89;
726 pub const EMULTIHOP
: ::c_int
= 90;
727 pub const ENOLINK
: ::c_int
= 91;
728 pub const EPROTO
: ::c_int
= 92;
730 pub const POLLSTANDARD
: ::c_short
= ::POLLIN
740 pub const AI_PASSIVE
: ::c_int
= 0x00000001;
741 pub const AI_CANONNAME
: ::c_int
= 0x00000002;
742 pub const AI_NUMERICHOST
: ::c_int
= 0x00000004;
743 pub const AI_NUMERICSERV
: ::c_int
= 0x00000008;
744 pub const AI_ALL
: ::c_int
= 0x00000100;
745 pub const AI_ADDRCONFIG
: ::c_int
= 0x00000400;
746 pub const AI_V4MAPPED
: ::c_int
= 0x00000800;
748 pub const EAI_AGAIN
: ::c_int
= 2;
749 pub const EAI_BADFLAGS
: ::c_int
= 3;
750 pub const EAI_FAIL
: ::c_int
= 4;
751 pub const EAI_FAMILY
: ::c_int
= 5;
752 pub const EAI_MEMORY
: ::c_int
= 6;
753 pub const EAI_NONAME
: ::c_int
= 8;
754 pub const EAI_SERVICE
: ::c_int
= 9;
755 pub const EAI_SOCKTYPE
: ::c_int
= 10;
756 pub const EAI_SYSTEM
: ::c_int
= 11;
757 pub const EAI_OVERFLOW
: ::c_int
= 14;
759 pub const F_DUPFD
: ::c_int
= 0;
760 pub const F_GETFD
: ::c_int
= 1;
761 pub const F_SETFD
: ::c_int
= 2;
762 pub const F_GETFL
: ::c_int
= 3;
763 pub const F_SETFL
: ::c_int
= 4;
765 pub const SIGTRAP
: ::c_int
= 5;
767 pub const GLOB_APPEND
: ::c_int
= 0x0001;
768 pub const GLOB_DOOFFS
: ::c_int
= 0x0002;
769 pub const GLOB_ERR
: ::c_int
= 0x0004;
770 pub const GLOB_MARK
: ::c_int
= 0x0008;
771 pub const GLOB_NOCHECK
: ::c_int
= 0x0010;
772 pub const GLOB_NOSORT
: ::c_int
= 0x0020;
773 pub const GLOB_NOESCAPE
: ::c_int
= 0x2000;
775 pub const GLOB_NOSPACE
: ::c_int
= -1;
776 pub const GLOB_ABORTED
: ::c_int
= -2;
777 pub const GLOB_NOMATCH
: ::c_int
= -3;
779 pub const POSIX_MADV_NORMAL
: ::c_int
= 0;
780 pub const POSIX_MADV_RANDOM
: ::c_int
= 1;
781 pub const POSIX_MADV_SEQUENTIAL
: ::c_int
= 2;
782 pub const POSIX_MADV_WILLNEED
: ::c_int
= 3;
783 pub const POSIX_MADV_DONTNEED
: ::c_int
= 4;
785 pub const PTHREAD_PROCESS_PRIVATE
: ::c_int
= 0;
786 pub const PTHREAD_PROCESS_SHARED
: ::c_int
= 1;
787 pub const PTHREAD_CREATE_JOINABLE
: ::c_int
= 0;
788 pub const PTHREAD_CREATE_DETACHED
: ::c_int
= 1;
790 pub const RLIMIT_CPU
: ::c_int
= 0;
791 pub const RLIMIT_FSIZE
: ::c_int
= 1;
792 pub const RLIMIT_DATA
: ::c_int
= 2;
793 pub const RLIMIT_STACK
: ::c_int
= 3;
794 pub const RLIMIT_CORE
: ::c_int
= 4;
795 pub const RLIMIT_RSS
: ::c_int
= 5;
796 pub const RLIMIT_MEMLOCK
: ::c_int
= 6;
797 pub const RLIMIT_NPROC
: ::c_int
= 7;
798 pub const RLIMIT_NOFILE
: ::c_int
= 8;
799 pub const RLIMIT_SBSIZE
: ::c_int
= 9;
800 pub const RLIMIT_VMEM
: ::c_int
= 10;
801 pub const RLIMIT_AS
: ::c_int
= RLIMIT_VMEM
;
802 pub const RLIM_INFINITY
: rlim_t
= 0x7fff_ffff_ffff_ffff;
804 pub const RUSAGE_SELF
: ::c_int
= 0;
805 pub const RUSAGE_CHILDREN
: ::c_int
= -1;
807 pub const CLOCK_REALTIME
: ::clockid_t
= 0;
808 pub const CLOCK_VIRTUAL
: ::clockid_t
= 1;
809 pub const CLOCK_PROF
: ::clockid_t
= 2;
810 pub const CLOCK_MONOTONIC
: ::clockid_t
= 4;
811 pub const CLOCK_UPTIME
: ::clockid_t
= 5;
812 pub const CLOCK_UPTIME_PRECISE
: ::clockid_t
= 7;
813 pub const CLOCK_UPTIME_FAST
: ::clockid_t
= 8;
814 pub const CLOCK_REALTIME_PRECISE
: ::clockid_t
= 9;
815 pub const CLOCK_REALTIME_FAST
: ::clockid_t
= 10;
816 pub const CLOCK_MONOTONIC_PRECISE
: ::clockid_t
= 11;
817 pub const CLOCK_MONOTONIC_FAST
: ::clockid_t
= 12;
818 pub const CLOCK_SECOND
: ::clockid_t
= 13;
819 pub const CLOCK_THREAD_CPUTIME_ID
: ::clockid_t
= 14;
820 pub const CLOCK_PROCESS_CPUTIME_ID
: ::clockid_t
= 15;
822 pub const MADV_NORMAL
: ::c_int
= 0;
823 pub const MADV_RANDOM
: ::c_int
= 1;
824 pub const MADV_SEQUENTIAL
: ::c_int
= 2;
825 pub const MADV_WILLNEED
: ::c_int
= 3;
826 pub const MADV_DONTNEED
: ::c_int
= 4;
827 pub const MADV_FREE
: ::c_int
= 5;
828 pub const MADV_NOSYNC
: ::c_int
= 6;
829 pub const MADV_AUTOSYNC
: ::c_int
= 7;
830 pub const MADV_NOCORE
: ::c_int
= 8;
831 pub const MADV_CORE
: ::c_int
= 9;
833 pub const MINCORE_INCORE
: ::c_int
= 0x1;
834 pub const MINCORE_REFERENCED
: ::c_int
= 0x2;
835 pub const MINCORE_MODIFIED
: ::c_int
= 0x4;
836 pub const MINCORE_REFERENCED_OTHER
: ::c_int
= 0x8;
837 pub const MINCORE_MODIFIED_OTHER
: ::c_int
= 0x10;
839 pub const AF_UNSPEC
: ::c_int
= 0;
840 pub const AF_LOCAL
: ::c_int
= 1;
841 pub const AF_UNIX
: ::c_int
= AF_LOCAL
;
842 pub const AF_INET
: ::c_int
= 2;
843 pub const AF_IMPLINK
: ::c_int
= 3;
844 pub const AF_PUP
: ::c_int
= 4;
845 pub const AF_CHAOS
: ::c_int
= 5;
846 pub const AF_NETBIOS
: ::c_int
= 6;
847 pub const AF_ISO
: ::c_int
= 7;
848 pub const AF_OSI
: ::c_int
= AF_ISO
;
849 pub const AF_ECMA
: ::c_int
= 8;
850 pub const AF_DATAKIT
: ::c_int
= 9;
851 pub const AF_CCITT
: ::c_int
= 10;
852 pub const AF_SNA
: ::c_int
= 11;
853 pub const AF_DECnet
: ::c_int
= 12;
854 pub const AF_DLI
: ::c_int
= 13;
855 pub const AF_LAT
: ::c_int
= 14;
856 pub const AF_HYLINK
: ::c_int
= 15;
857 pub const AF_APPLETALK
: ::c_int
= 16;
858 pub const AF_ROUTE
: ::c_int
= 17;
859 pub const AF_LINK
: ::c_int
= 18;
860 pub const pseudo_AF_XTP
: ::c_int
= 19;
861 pub const AF_COIP
: ::c_int
= 20;
862 pub const AF_CNT
: ::c_int
= 21;
863 pub const pseudo_AF_RTIP
: ::c_int
= 22;
864 pub const AF_IPX
: ::c_int
= 23;
865 pub const AF_SIP
: ::c_int
= 24;
866 pub const pseudo_AF_PIP
: ::c_int
= 25;
867 pub const AF_ISDN
: ::c_int
= 26;
868 pub const AF_E164
: ::c_int
= AF_ISDN
;
869 pub const pseudo_AF_KEY
: ::c_int
= 27;
870 pub const AF_INET6
: ::c_int
= 28;
871 pub const AF_NATM
: ::c_int
= 29;
872 pub const AF_ATM
: ::c_int
= 30;
873 pub const pseudo_AF_HDRCMPLT
: ::c_int
= 31;
874 pub const AF_NETGRAPH
: ::c_int
= 32;
876 pub const PF_UNSPEC
: ::c_int
= AF_UNSPEC
;
877 pub const PF_LOCAL
: ::c_int
= AF_LOCAL
;
878 pub const PF_UNIX
: ::c_int
= PF_LOCAL
;
879 pub const PF_INET
: ::c_int
= AF_INET
;
880 pub const PF_IMPLINK
: ::c_int
= AF_IMPLINK
;
881 pub const PF_PUP
: ::c_int
= AF_PUP
;
882 pub const PF_CHAOS
: ::c_int
= AF_CHAOS
;
883 pub const PF_NETBIOS
: ::c_int
= AF_NETBIOS
;
884 pub const PF_ISO
: ::c_int
= AF_ISO
;
885 pub const PF_OSI
: ::c_int
= AF_ISO
;
886 pub const PF_ECMA
: ::c_int
= AF_ECMA
;
887 pub const PF_DATAKIT
: ::c_int
= AF_DATAKIT
;
888 pub const PF_CCITT
: ::c_int
= AF_CCITT
;
889 pub const PF_SNA
: ::c_int
= AF_SNA
;
890 pub const PF_DECnet
: ::c_int
= AF_DECnet
;
891 pub const PF_DLI
: ::c_int
= AF_DLI
;
892 pub const PF_LAT
: ::c_int
= AF_LAT
;
893 pub const PF_HYLINK
: ::c_int
= AF_HYLINK
;
894 pub const PF_APPLETALK
: ::c_int
= AF_APPLETALK
;
895 pub const PF_ROUTE
: ::c_int
= AF_ROUTE
;
896 pub const PF_LINK
: ::c_int
= AF_LINK
;
897 pub const PF_XTP
: ::c_int
= pseudo_AF_XTP
;
898 pub const PF_COIP
: ::c_int
= AF_COIP
;
899 pub const PF_CNT
: ::c_int
= AF_CNT
;
900 pub const PF_SIP
: ::c_int
= AF_SIP
;
901 pub const PF_IPX
: ::c_int
= AF_IPX
;
902 pub const PF_RTIP
: ::c_int
= pseudo_AF_RTIP
;
903 pub const PF_PIP
: ::c_int
= pseudo_AF_PIP
;
904 pub const PF_ISDN
: ::c_int
= AF_ISDN
;
905 pub const PF_KEY
: ::c_int
= pseudo_AF_KEY
;
906 pub const PF_INET6
: ::c_int
= AF_INET6
;
907 pub const PF_NATM
: ::c_int
= AF_NATM
;
908 pub const PF_ATM
: ::c_int
= AF_ATM
;
909 pub const PF_NETGRAPH
: ::c_int
= AF_NETGRAPH
;
911 pub const PIOD_READ_D
: ::c_int
= 1;
912 pub const PIOD_WRITE_D
: ::c_int
= 2;
913 pub const PIOD_READ_I
: ::c_int
= 3;
914 pub const PIOD_WRITE_I
: ::c_int
= 4;
916 pub const PT_TRACE_ME
: ::c_int
= 0;
917 pub const PT_READ_I
: ::c_int
= 1;
918 pub const PT_READ_D
: ::c_int
= 2;
919 pub const PT_WRITE_I
: ::c_int
= 4;
920 pub const PT_WRITE_D
: ::c_int
= 5;
921 pub const PT_CONTINUE
: ::c_int
= 7;
922 pub const PT_KILL
: ::c_int
= 8;
923 pub const PT_STEP
: ::c_int
= 9;
924 pub const PT_ATTACH
: ::c_int
= 10;
925 pub const PT_DETACH
: ::c_int
= 11;
926 pub const PT_IO
: ::c_int
= 12;
928 pub const SOMAXCONN
: ::c_int
= 128;
930 pub const MSG_OOB
: ::c_int
= 0x00000001;
931 pub const MSG_PEEK
: ::c_int
= 0x00000002;
932 pub const MSG_DONTROUTE
: ::c_int
= 0x00000004;
933 pub const MSG_EOR
: ::c_int
= 0x00000008;
934 pub const MSG_TRUNC
: ::c_int
= 0x00000010;
935 pub const MSG_CTRUNC
: ::c_int
= 0x00000020;
936 pub const MSG_WAITALL
: ::c_int
= 0x00000040;
937 pub const MSG_DONTWAIT
: ::c_int
= 0x00000080;
938 pub const MSG_EOF
: ::c_int
= 0x00000100;
940 pub const SCM_TIMESTAMP
: ::c_int
= 0x02;
941 pub const SCM_CREDS
: ::c_int
= 0x03;
943 pub const SOCK_STREAM
: ::c_int
= 1;
944 pub const SOCK_DGRAM
: ::c_int
= 2;
945 pub const SOCK_RAW
: ::c_int
= 3;
946 pub const SOCK_RDM
: ::c_int
= 4;
947 pub const SOCK_SEQPACKET
: ::c_int
= 5;
948 pub const SOCK_CLOEXEC
: ::c_int
= 0x10000000;
949 pub const SOCK_NONBLOCK
: ::c_int
= 0x20000000;
950 pub const SOCK_MAXADDRLEN
: ::c_int
= 255;
951 pub const IP_TTL
: ::c_int
= 4;
952 pub const IP_HDRINCL
: ::c_int
= 2;
953 pub const IP_RECVDSTADDR
: ::c_int
= 7;
954 pub const IP_SENDSRCADDR
: ::c_int
= IP_RECVDSTADDR
;
955 pub const IP_ADD_MEMBERSHIP
: ::c_int
= 12;
956 pub const IP_DROP_MEMBERSHIP
: ::c_int
= 13;
957 pub const IP_RECVIF
: ::c_int
= 20;
958 pub const IPV6_JOIN_GROUP
: ::c_int
= 12;
959 pub const IPV6_LEAVE_GROUP
: ::c_int
= 13;
960 pub const IPV6_CHECKSUM
: ::c_int
= 26;
961 pub const IPV6_RECVPKTINFO
: ::c_int
= 36;
962 pub const IPV6_PKTINFO
: ::c_int
= 46;
963 pub const IPV6_HOPLIMIT
: ::c_int
= 47;
964 pub const IPV6_RECVTCLASS
: ::c_int
= 57;
965 pub const IPV6_TCLASS
: ::c_int
= 61;
967 pub const TCP_NOPUSH
: ::c_int
= 4;
968 pub const TCP_NOOPT
: ::c_int
= 8;
969 pub const TCP_KEEPIDLE
: ::c_int
= 256;
970 pub const TCP_KEEPINTVL
: ::c_int
= 512;
971 pub const TCP_KEEPCNT
: ::c_int
= 1024;
973 pub const SOL_SOCKET
: ::c_int
= 0xffff;
974 pub const SO_DEBUG
: ::c_int
= 0x01;
975 pub const SO_ACCEPTCONN
: ::c_int
= 0x0002;
976 pub const SO_REUSEADDR
: ::c_int
= 0x0004;
977 pub const SO_KEEPALIVE
: ::c_int
= 0x0008;
978 pub const SO_DONTROUTE
: ::c_int
= 0x0010;
979 pub const SO_BROADCAST
: ::c_int
= 0x0020;
980 pub const SO_USELOOPBACK
: ::c_int
= 0x0040;
981 pub const SO_LINGER
: ::c_int
= 0x0080;
982 pub const SO_OOBINLINE
: ::c_int
= 0x0100;
983 pub const SO_REUSEPORT
: ::c_int
= 0x0200;
984 pub const SO_TIMESTAMP
: ::c_int
= 0x0400;
985 pub const SO_NOSIGPIPE
: ::c_int
= 0x0800;
986 pub const SO_ACCEPTFILTER
: ::c_int
= 0x1000;
987 pub const SO_SNDBUF
: ::c_int
= 0x1001;
988 pub const SO_RCVBUF
: ::c_int
= 0x1002;
989 pub const SO_SNDLOWAT
: ::c_int
= 0x1003;
990 pub const SO_RCVLOWAT
: ::c_int
= 0x1004;
991 pub const SO_SNDTIMEO
: ::c_int
= 0x1005;
992 pub const SO_RCVTIMEO
: ::c_int
= 0x1006;
993 pub const SO_ERROR
: ::c_int
= 0x1007;
994 pub const SO_TYPE
: ::c_int
= 0x1008;
996 pub const LOCAL_PEERCRED
: ::c_int
= 1;
998 pub const SHUT_RD
: ::c_int
= 0;
999 pub const SHUT_WR
: ::c_int
= 1;
1000 pub const SHUT_RDWR
: ::c_int
= 2;
1002 pub const LOCK_SH
: ::c_int
= 1;
1003 pub const LOCK_EX
: ::c_int
= 2;
1004 pub const LOCK_NB
: ::c_int
= 4;
1005 pub const LOCK_UN
: ::c_int
= 8;
1007 pub const MAP_COPY
: ::c_int
= 0x0002;
1011 note
= "Removed in FreeBSD 11, unused in DragonFlyBSD"
1013 pub const MAP_RENAME
: ::c_int
= 0x0020;
1017 note
= "Removed in FreeBSD 11, unused in DragonFlyBSD"
1019 pub const MAP_NORESERVE
: ::c_int
= 0x0040;
1020 pub const MAP_HASSEMAPHORE
: ::c_int
= 0x0200;
1021 pub const MAP_STACK
: ::c_int
= 0x0400;
1022 pub const MAP_NOSYNC
: ::c_int
= 0x0800;
1023 pub const MAP_NOCORE
: ::c_int
= 0x020000;
1025 pub const IPPROTO_RAW
: ::c_int
= 255;
1027 pub const _PC_LINK_MAX
: ::c_int
= 1;
1028 pub const _PC_MAX_CANON
: ::c_int
= 2;
1029 pub const _PC_MAX_INPUT
: ::c_int
= 3;
1030 pub const _PC_NAME_MAX
: ::c_int
= 4;
1031 pub const _PC_PATH_MAX
: ::c_int
= 5;
1032 pub const _PC_PIPE_BUF
: ::c_int
= 6;
1033 pub const _PC_CHOWN_RESTRICTED
: ::c_int
= 7;
1034 pub const _PC_NO_TRUNC
: ::c_int
= 8;
1035 pub const _PC_VDISABLE
: ::c_int
= 9;
1036 pub const _PC_ALLOC_SIZE_MIN
: ::c_int
= 10;
1037 pub const _PC_FILESIZEBITS
: ::c_int
= 12;
1038 pub const _PC_REC_INCR_XFER_SIZE
: ::c_int
= 14;
1039 pub const _PC_REC_MAX_XFER_SIZE
: ::c_int
= 15;
1040 pub const _PC_REC_MIN_XFER_SIZE
: ::c_int
= 16;
1041 pub const _PC_REC_XFER_ALIGN
: ::c_int
= 17;
1042 pub const _PC_SYMLINK_MAX
: ::c_int
= 18;
1043 pub const _PC_MIN_HOLE_SIZE
: ::c_int
= 21;
1044 pub const _PC_ASYNC_IO
: ::c_int
= 53;
1045 pub const _PC_PRIO_IO
: ::c_int
= 54;
1046 pub const _PC_SYNC_IO
: ::c_int
= 55;
1047 pub const _PC_ACL_EXTENDED
: ::c_int
= 59;
1048 pub const _PC_ACL_PATH_MAX
: ::c_int
= 60;
1049 pub const _PC_CAP_PRESENT
: ::c_int
= 61;
1050 pub const _PC_INF_PRESENT
: ::c_int
= 62;
1051 pub const _PC_MAC_PRESENT
: ::c_int
= 63;
1053 pub const _SC_ARG_MAX
: ::c_int
= 1;
1054 pub const _SC_CHILD_MAX
: ::c_int
= 2;
1055 pub const _SC_CLK_TCK
: ::c_int
= 3;
1056 pub const _SC_NGROUPS_MAX
: ::c_int
= 4;
1057 pub const _SC_OPEN_MAX
: ::c_int
= 5;
1058 pub const _SC_JOB_CONTROL
: ::c_int
= 6;
1059 pub const _SC_SAVED_IDS
: ::c_int
= 7;
1060 pub const _SC_VERSION
: ::c_int
= 8;
1061 pub const _SC_BC_BASE_MAX
: ::c_int
= 9;
1062 pub const _SC_BC_DIM_MAX
: ::c_int
= 10;
1063 pub const _SC_BC_SCALE_MAX
: ::c_int
= 11;
1064 pub const _SC_BC_STRING_MAX
: ::c_int
= 12;
1065 pub const _SC_COLL_WEIGHTS_MAX
: ::c_int
= 13;
1066 pub const _SC_EXPR_NEST_MAX
: ::c_int
= 14;
1067 pub const _SC_LINE_MAX
: ::c_int
= 15;
1068 pub const _SC_RE_DUP_MAX
: ::c_int
= 16;
1069 pub const _SC_2_VERSION
: ::c_int
= 17;
1070 pub const _SC_2_C_BIND
: ::c_int
= 18;
1071 pub const _SC_2_C_DEV
: ::c_int
= 19;
1072 pub const _SC_2_CHAR_TERM
: ::c_int
= 20;
1073 pub const _SC_2_FORT_DEV
: ::c_int
= 21;
1074 pub const _SC_2_FORT_RUN
: ::c_int
= 22;
1075 pub const _SC_2_LOCALEDEF
: ::c_int
= 23;
1076 pub const _SC_2_SW_DEV
: ::c_int
= 24;
1077 pub const _SC_2_UPE
: ::c_int
= 25;
1078 pub const _SC_STREAM_MAX
: ::c_int
= 26;
1079 pub const _SC_TZNAME_MAX
: ::c_int
= 27;
1080 pub const _SC_ASYNCHRONOUS_IO
: ::c_int
= 28;
1081 pub const _SC_MAPPED_FILES
: ::c_int
= 29;
1082 pub const _SC_MEMLOCK
: ::c_int
= 30;
1083 pub const _SC_MEMLOCK_RANGE
: ::c_int
= 31;
1084 pub const _SC_MEMORY_PROTECTION
: ::c_int
= 32;
1085 pub const _SC_MESSAGE_PASSING
: ::c_int
= 33;
1086 pub const _SC_PRIORITIZED_IO
: ::c_int
= 34;
1087 pub const _SC_PRIORITY_SCHEDULING
: ::c_int
= 35;
1088 pub const _SC_REALTIME_SIGNALS
: ::c_int
= 36;
1089 pub const _SC_SEMAPHORES
: ::c_int
= 37;
1090 pub const _SC_FSYNC
: ::c_int
= 38;
1091 pub const _SC_SHARED_MEMORY_OBJECTS
: ::c_int
= 39;
1092 pub const _SC_SYNCHRONIZED_IO
: ::c_int
= 40;
1093 pub const _SC_TIMERS
: ::c_int
= 41;
1094 pub const _SC_AIO_LISTIO_MAX
: ::c_int
= 42;
1095 pub const _SC_AIO_MAX
: ::c_int
= 43;
1096 pub const _SC_AIO_PRIO_DELTA_MAX
: ::c_int
= 44;
1097 pub const _SC_DELAYTIMER_MAX
: ::c_int
= 45;
1098 pub const _SC_MQ_OPEN_MAX
: ::c_int
= 46;
1099 pub const _SC_PAGESIZE
: ::c_int
= 47;
1100 pub const _SC_PAGE_SIZE
: ::c_int
= _SC_PAGESIZE
;
1101 pub const _SC_RTSIG_MAX
: ::c_int
= 48;
1102 pub const _SC_SEM_NSEMS_MAX
: ::c_int
= 49;
1103 pub const _SC_SEM_VALUE_MAX
: ::c_int
= 50;
1104 pub const _SC_SIGQUEUE_MAX
: ::c_int
= 51;
1105 pub const _SC_TIMER_MAX
: ::c_int
= 52;
1106 pub const _SC_IOV_MAX
: ::c_int
= 56;
1107 pub const _SC_NPROCESSORS_CONF
: ::c_int
= 57;
1108 pub const _SC_2_PBS
: ::c_int
= 59;
1109 pub const _SC_2_PBS_ACCOUNTING
: ::c_int
= 60;
1110 pub const _SC_2_PBS_CHECKPOINT
: ::c_int
= 61;
1111 pub const _SC_2_PBS_LOCATE
: ::c_int
= 62;
1112 pub const _SC_2_PBS_MESSAGE
: ::c_int
= 63;
1113 pub const _SC_2_PBS_TRACK
: ::c_int
= 64;
1114 pub const _SC_ADVISORY_INFO
: ::c_int
= 65;
1115 pub const _SC_BARRIERS
: ::c_int
= 66;
1116 pub const _SC_CLOCK_SELECTION
: ::c_int
= 67;
1117 pub const _SC_CPUTIME
: ::c_int
= 68;
1118 pub const _SC_FILE_LOCKING
: ::c_int
= 69;
1119 pub const _SC_NPROCESSORS_ONLN
: ::c_int
= 58;
1120 pub const _SC_GETGR_R_SIZE_MAX
: ::c_int
= 70;
1121 pub const _SC_GETPW_R_SIZE_MAX
: ::c_int
= 71;
1122 pub const _SC_HOST_NAME_MAX
: ::c_int
= 72;
1123 pub const _SC_LOGIN_NAME_MAX
: ::c_int
= 73;
1124 pub const _SC_MONOTONIC_CLOCK
: ::c_int
= 74;
1125 pub const _SC_MQ_PRIO_MAX
: ::c_int
= 75;
1126 pub const _SC_READER_WRITER_LOCKS
: ::c_int
= 76;
1127 pub const _SC_REGEXP
: ::c_int
= 77;
1128 pub const _SC_SHELL
: ::c_int
= 78;
1129 pub const _SC_SPAWN
: ::c_int
= 79;
1130 pub const _SC_SPIN_LOCKS
: ::c_int
= 80;
1131 pub const _SC_SPORADIC_SERVER
: ::c_int
= 81;
1132 pub const _SC_THREAD_ATTR_STACKADDR
: ::c_int
= 82;
1133 pub const _SC_THREAD_ATTR_STACKSIZE
: ::c_int
= 83;
1134 pub const _SC_THREAD_DESTRUCTOR_ITERATIONS
: ::c_int
= 85;
1135 pub const _SC_THREAD_KEYS_MAX
: ::c_int
= 86;
1136 pub const _SC_THREAD_PRIO_INHERIT
: ::c_int
= 87;
1137 pub const _SC_THREAD_PRIO_PROTECT
: ::c_int
= 88;
1138 pub const _SC_THREAD_PRIORITY_SCHEDULING
: ::c_int
= 89;
1139 pub const _SC_THREAD_PROCESS_SHARED
: ::c_int
= 90;
1140 pub const _SC_THREAD_SAFE_FUNCTIONS
: ::c_int
= 91;
1141 pub const _SC_THREAD_SPORADIC_SERVER
: ::c_int
= 92;
1142 pub const _SC_THREAD_STACK_MIN
: ::c_int
= 93;
1143 pub const _SC_THREAD_THREADS_MAX
: ::c_int
= 94;
1144 pub const _SC_TIMEOUTS
: ::c_int
= 95;
1145 pub const _SC_THREADS
: ::c_int
= 96;
1146 pub const _SC_TRACE
: ::c_int
= 97;
1147 pub const _SC_TRACE_EVENT_FILTER
: ::c_int
= 98;
1148 pub const _SC_TRACE_INHERIT
: ::c_int
= 99;
1149 pub const _SC_TRACE_LOG
: ::c_int
= 100;
1150 pub const _SC_TTY_NAME_MAX
: ::c_int
= 101;
1151 pub const _SC_TYPED_MEMORY_OBJECTS
: ::c_int
= 102;
1152 pub const _SC_V6_ILP32_OFF32
: ::c_int
= 103;
1153 pub const _SC_V6_ILP32_OFFBIG
: ::c_int
= 104;
1154 pub const _SC_V6_LP64_OFF64
: ::c_int
= 105;
1155 pub const _SC_V6_LPBIG_OFFBIG
: ::c_int
= 106;
1156 pub const _SC_ATEXIT_MAX
: ::c_int
= 107;
1157 pub const _SC_XOPEN_CRYPT
: ::c_int
= 108;
1158 pub const _SC_XOPEN_ENH_I18N
: ::c_int
= 109;
1159 pub const _SC_XOPEN_LEGACY
: ::c_int
= 110;
1160 pub const _SC_XOPEN_REALTIME
: ::c_int
= 111;
1161 pub const _SC_XOPEN_REALTIME_THREADS
: ::c_int
= 112;
1162 pub const _SC_XOPEN_SHM
: ::c_int
= 113;
1163 pub const _SC_XOPEN_STREAMS
: ::c_int
= 114;
1164 pub const _SC_XOPEN_UNIX
: ::c_int
= 115;
1165 pub const _SC_XOPEN_VERSION
: ::c_int
= 116;
1166 pub const _SC_XOPEN_XCU_VERSION
: ::c_int
= 117;
1167 pub const _SC_IPV6
: ::c_int
= 118;
1168 pub const _SC_RAW_SOCKETS
: ::c_int
= 119;
1169 pub const _SC_SYMLOOP_MAX
: ::c_int
= 120;
1170 pub const _SC_PHYS_PAGES
: ::c_int
= 121;
1172 pub const PTHREAD_MUTEX_INITIALIZER
: pthread_mutex_t
= 0 as *mut _
;
1173 pub const PTHREAD_COND_INITIALIZER
: pthread_cond_t
= 0 as *mut _
;
1174 pub const PTHREAD_RWLOCK_INITIALIZER
: pthread_rwlock_t
= 0 as *mut _
;
1175 pub const PTHREAD_MUTEX_ERRORCHECK
: ::c_int
= 1;
1176 pub const PTHREAD_MUTEX_RECURSIVE
: ::c_int
= 2;
1177 pub const PTHREAD_MUTEX_NORMAL
: ::c_int
= 3;
1178 pub const PTHREAD_MUTEX_DEFAULT
: ::c_int
= PTHREAD_MUTEX_ERRORCHECK
;
1180 pub const SCHED_FIFO
: ::c_int
= 1;
1181 pub const SCHED_OTHER
: ::c_int
= 2;
1182 pub const SCHED_RR
: ::c_int
= 3;
1184 pub const FD_SETSIZE
: usize = 1024;
1186 pub const ST_NOSUID
: ::c_ulong
= 2;
1188 pub const NI_MAXHOST
: ::size_t
= 1025;
1190 pub const XUCRED_VERSION
: ::c_uint
= 0;
1192 pub const RTLD_LOCAL
: ::c_int
= 0;
1193 pub const RTLD_NODELETE
: ::c_int
= 0x1000;
1194 pub const RTLD_NOLOAD
: ::c_int
= 0x2000;
1195 pub const RTLD_GLOBAL
: ::c_int
= 0x100;
1197 pub const LOG_NTP
: ::c_int
= 12 << 3;
1198 pub const LOG_SECURITY
: ::c_int
= 13 << 3;
1199 pub const LOG_CONSOLE
: ::c_int
= 14 << 3;
1200 pub const LOG_NFACILITIES
: ::c_int
= 24;
1202 pub const TIOCEXCL
: ::c_ulong
= 0x2000740d;
1203 pub const TIOCNXCL
: ::c_ulong
= 0x2000740e;
1204 pub const TIOCFLUSH
: ::c_ulong
= 0x80047410;
1205 pub const TIOCGETA
: ::c_ulong
= 0x402c7413;
1206 pub const TIOCSETA
: ::c_ulong
= 0x802c7414;
1207 pub const TIOCSETAW
: ::c_ulong
= 0x802c7415;
1208 pub const TIOCSETAF
: ::c_ulong
= 0x802c7416;
1209 pub const TIOCGETD
: ::c_ulong
= 0x4004741a;
1210 pub const TIOCSETD
: ::c_ulong
= 0x8004741b;
1211 pub const TIOCGDRAINWAIT
: ::c_ulong
= 0x40047456;
1212 pub const TIOCSDRAINWAIT
: ::c_ulong
= 0x80047457;
1213 pub const TIOCTIMESTAMP
: ::c_ulong
= 0x40107459;
1214 pub const TIOCMGDTRWAIT
: ::c_ulong
= 0x4004745a;
1215 pub const TIOCMSDTRWAIT
: ::c_ulong
= 0x8004745b;
1216 pub const TIOCDRAIN
: ::c_ulong
= 0x2000745e;
1217 pub const TIOCEXT
: ::c_ulong
= 0x80047460;
1218 pub const TIOCSCTTY
: ::c_ulong
= 0x20007461;
1219 pub const TIOCCONS
: ::c_ulong
= 0x80047462;
1220 pub const TIOCGSID
: ::c_ulong
= 0x40047463;
1221 pub const TIOCSTAT
: ::c_ulong
= 0x20007465;
1222 pub const TIOCUCNTL
: ::c_ulong
= 0x80047466;
1223 pub const TIOCSWINSZ
: ::c_ulong
= 0x80087467;
1224 pub const TIOCGWINSZ
: ::c_ulong
= 0x40087468;
1225 pub const TIOCMGET
: ::c_ulong
= 0x4004746a;
1226 pub const TIOCM_LE
: ::c_int
= 0x1;
1227 pub const TIOCM_DTR
: ::c_int
= 0x2;
1228 pub const TIOCM_RTS
: ::c_int
= 0x4;
1229 pub const TIOCM_ST
: ::c_int
= 0x8;
1230 pub const TIOCM_SR
: ::c_int
= 0x10;
1231 pub const TIOCM_CTS
: ::c_int
= 0x20;
1232 pub const TIOCM_RI
: ::c_int
= 0x80;
1233 pub const TIOCM_DSR
: ::c_int
= 0x100;
1234 pub const TIOCM_CD
: ::c_int
= 0x40;
1235 pub const TIOCM_CAR
: ::c_int
= 0x40;
1236 pub const TIOCM_RNG
: ::c_int
= 0x80;
1237 pub const TIOCMBIC
: ::c_ulong
= 0x8004746b;
1238 pub const TIOCMBIS
: ::c_ulong
= 0x8004746c;
1239 pub const TIOCMSET
: ::c_ulong
= 0x8004746d;
1240 pub const TIOCSTART
: ::c_ulong
= 0x2000746e;
1241 pub const TIOCSTOP
: ::c_ulong
= 0x2000746f;
1242 pub const TIOCPKT
: ::c_ulong
= 0x80047470;
1243 pub const TIOCPKT_DATA
: ::c_int
= 0x0;
1244 pub const TIOCPKT_FLUSHREAD
: ::c_int
= 0x1;
1245 pub const TIOCPKT_FLUSHWRITE
: ::c_int
= 0x2;
1246 pub const TIOCPKT_STOP
: ::c_int
= 0x4;
1247 pub const TIOCPKT_START
: ::c_int
= 0x8;
1248 pub const TIOCPKT_NOSTOP
: ::c_int
= 0x10;
1249 pub const TIOCPKT_DOSTOP
: ::c_int
= 0x20;
1250 pub const TIOCPKT_IOCTL
: ::c_int
= 0x40;
1251 pub const TIOCNOTTY
: ::c_ulong
= 0x20007471;
1252 pub const TIOCSTI
: ::c_ulong
= 0x80017472;
1253 pub const TIOCOUTQ
: ::c_ulong
= 0x40047473;
1254 pub const TIOCSPGRP
: ::c_ulong
= 0x80047476;
1255 pub const TIOCGPGRP
: ::c_ulong
= 0x40047477;
1256 pub const TIOCCDTR
: ::c_ulong
= 0x20007478;
1257 pub const TIOCSDTR
: ::c_ulong
= 0x20007479;
1258 pub const TTYDISC
: ::c_int
= 0x0;
1259 pub const SLIPDISC
: ::c_int
= 0x4;
1260 pub const PPPDISC
: ::c_int
= 0x5;
1261 pub const NETGRAPHDISC
: ::c_int
= 0x6;
1263 pub const BIOCGRSIG
: ::c_ulong
= 0x40044272;
1264 pub const BIOCSRSIG
: ::c_ulong
= 0x80044273;
1265 pub const BIOCSDLT
: ::c_ulong
= 0x80044278;
1266 pub const BIOCGSEESENT
: ::c_ulong
= 0x40044276;
1267 pub const BIOCSSEESENT
: ::c_ulong
= 0x80044277;
1268 pub const BIOCSETF
: ::c_ulong
= 0x80104267;
1269 pub const BIOCGDLTLIST
: ::c_ulong
= 0xc0104279;
1270 pub const BIOCSRTIMEOUT
: ::c_ulong
= 0x8010426d;
1271 pub const BIOCGRTIMEOUT
: ::c_ulong
= 0x4010426e;
1273 pub const FIODTYPE
: ::c_ulong
= 0x4004667a;
1274 pub const FIOGETLBA
: ::c_ulong
= 0x40046679;
1276 pub const B0
: speed_t
= 0;
1277 pub const B50
: speed_t
= 50;
1278 pub const B75
: speed_t
= 75;
1279 pub const B110
: speed_t
= 110;
1280 pub const B134
: speed_t
= 134;
1281 pub const B150
: speed_t
= 150;
1282 pub const B200
: speed_t
= 200;
1283 pub const B300
: speed_t
= 300;
1284 pub const B600
: speed_t
= 600;
1285 pub const B1200
: speed_t
= 1200;
1286 pub const B1800
: speed_t
= 1800;
1287 pub const B2400
: speed_t
= 2400;
1288 pub const B4800
: speed_t
= 4800;
1289 pub const B9600
: speed_t
= 9600;
1290 pub const B19200
: speed_t
= 19200;
1291 pub const B38400
: speed_t
= 38400;
1292 pub const B7200
: speed_t
= 7200;
1293 pub const B14400
: speed_t
= 14400;
1294 pub const B28800
: speed_t
= 28800;
1295 pub const B57600
: speed_t
= 57600;
1296 pub const B76800
: speed_t
= 76800;
1297 pub const B115200
: speed_t
= 115200;
1298 pub const B230400
: speed_t
= 230400;
1299 pub const EXTA
: speed_t
= 19200;
1300 pub const EXTB
: speed_t
= 38400;
1302 pub const SEM_FAILED
: *mut sem_t
= 0 as *mut sem_t
;
1304 pub const CRTSCTS
: ::tcflag_t
= 0x00030000;
1305 pub const CCTS_OFLOW
: ::tcflag_t
= 0x00010000;
1306 pub const CRTS_IFLOW
: ::tcflag_t
= 0x00020000;
1307 pub const CDTR_IFLOW
: ::tcflag_t
= 0x00040000;
1308 pub const CDSR_OFLOW
: ::tcflag_t
= 0x00080000;
1309 pub const CCAR_OFLOW
: ::tcflag_t
= 0x00100000;
1310 pub const VERASE2
: usize = 7;
1311 pub const OCRNL
: ::tcflag_t
= 0x10;
1312 pub const ONOCR
: ::tcflag_t
= 0x20;
1313 pub const ONLRET
: ::tcflag_t
= 0x40;
1315 pub const CMGROUP_MAX
: usize = 16;
1317 // https://github.com/freebsd/freebsd/blob/master/sys/net/bpf.h
1318 pub const BPF_ALIGNMENT
: usize = SIZEOF_LONG
;
1320 // Values for rtprio struct (prio field) and syscall (function argument)
1321 pub const RTP_PRIO_MIN
: ::c_ushort
= 0;
1322 pub const RTP_PRIO_MAX
: ::c_ushort
= 31;
1323 pub const RTP_LOOKUP
: ::c_int
= 0;
1324 pub const RTP_SET
: ::c_int
= 1;
1326 // Flags for chflags(2)
1327 pub const UF_SETTABLE
: ::c_ulong
= 0x0000ffff;
1328 pub const UF_NODUMP
: ::c_ulong
= 0x00000001;
1329 pub const UF_IMMUTABLE
: ::c_ulong
= 0x00000002;
1330 pub const UF_APPEND
: ::c_ulong
= 0x00000004;
1331 pub const UF_OPAQUE
: ::c_ulong
= 0x00000008;
1332 pub const UF_NOUNLINK
: ::c_ulong
= 0x00000010;
1333 pub const SF_SETTABLE
: ::c_ulong
= 0xffff0000;
1334 pub const SF_ARCHIVED
: ::c_ulong
= 0x00010000;
1335 pub const SF_IMMUTABLE
: ::c_ulong
= 0x00020000;
1336 pub const SF_APPEND
: ::c_ulong
= 0x00040000;
1337 pub const SF_NOUNLINK
: ::c_ulong
= 0x00100000;
1339 pub const TIMER_ABSTIME
: ::c_int
= 1;
1342 pub const NTP_API
: ::c_int
= 4;
1343 pub const MAXPHASE
: ::c_long
= 500000000;
1344 pub const MAXFREQ
: ::c_long
= 500000;
1345 pub const MINSEC
: ::c_int
= 256;
1346 pub const MAXSEC
: ::c_int
= 2048;
1347 pub const NANOSECOND
: ::c_long
= 1000000000;
1348 pub const SCALE_PPM
: ::c_int
= 65;
1349 pub const MAXTC
: ::c_int
= 10;
1350 pub const MOD_OFFSET
: ::c_uint
= 0x0001;
1351 pub const MOD_FREQUENCY
: ::c_uint
= 0x0002;
1352 pub const MOD_MAXERROR
: ::c_uint
= 0x0004;
1353 pub const MOD_ESTERROR
: ::c_uint
= 0x0008;
1354 pub const MOD_STATUS
: ::c_uint
= 0x0010;
1355 pub const MOD_TIMECONST
: ::c_uint
= 0x0020;
1356 pub const MOD_PPSMAX
: ::c_uint
= 0x0040;
1357 pub const MOD_TAI
: ::c_uint
= 0x0080;
1358 pub const MOD_MICRO
: ::c_uint
= 0x1000;
1359 pub const MOD_NANO
: ::c_uint
= 0x2000;
1360 pub const MOD_CLKB
: ::c_uint
= 0x4000;
1361 pub const MOD_CLKA
: ::c_uint
= 0x8000;
1362 pub const STA_PLL
: ::c_int
= 0x0001;
1363 pub const STA_PPSFREQ
: ::c_int
= 0x0002;
1364 pub const STA_PPSTIME
: ::c_int
= 0x0004;
1365 pub const STA_FLL
: ::c_int
= 0x0008;
1366 pub const STA_INS
: ::c_int
= 0x0010;
1367 pub const STA_DEL
: ::c_int
= 0x0020;
1368 pub const STA_UNSYNC
: ::c_int
= 0x0040;
1369 pub const STA_FREQHOLD
: ::c_int
= 0x0080;
1370 pub const STA_PPSSIGNAL
: ::c_int
= 0x0100;
1371 pub const STA_PPSJITTER
: ::c_int
= 0x0200;
1372 pub const STA_PPSWANDER
: ::c_int
= 0x0400;
1373 pub const STA_PPSERROR
: ::c_int
= 0x0800;
1374 pub const STA_CLOCKERR
: ::c_int
= 0x1000;
1375 pub const STA_NANO
: ::c_int
= 0x2000;
1376 pub const STA_MODE
: ::c_int
= 0x4000;
1377 pub const STA_CLK
: ::c_int
= 0x8000;
1378 pub const STA_RONLY
: ::c_int
= STA_PPSSIGNAL
1386 pub const TIME_OK
: ::c_int
= 0;
1387 pub const TIME_INS
: ::c_int
= 1;
1388 pub const TIME_DEL
: ::c_int
= 2;
1389 pub const TIME_OOP
: ::c_int
= 3;
1390 pub const TIME_WAIT
: ::c_int
= 4;
1391 pub const TIME_ERROR
: ::c_int
= 5;
1393 pub const REG_ENOSYS
: ::c_int
= -1;
1394 pub const REG_ILLSEQ
: ::c_int
= 17;
1396 pub const IPC_PRIVATE
: ::key_t
= 0;
1397 pub const IPC_CREAT
: ::c_int
= 0o1000;
1398 pub const IPC_EXCL
: ::c_int
= 0o2000;
1399 pub const IPC_NOWAIT
: ::c_int
= 0o4000;
1400 pub const IPC_RMID
: ::c_int
= 0;
1401 pub const IPC_SET
: ::c_int
= 1;
1402 pub const IPC_STAT
: ::c_int
= 2;
1403 pub const IPC_R
: ::c_int
= 0o400;
1404 pub const IPC_W
: ::c_int
= 0o200;
1405 pub const IPC_M
: ::c_int
= 0o10000;
1407 pub const SHM_RDONLY
: ::c_int
= 0o10000;
1408 pub const SHM_RND
: ::c_int
= 0o20000;
1409 pub const SHM_R
: ::c_int
= 0o400;
1410 pub const SHM_W
: ::c_int
= 0o200;
1413 pub {const}
fn WIFCONTINUED(status
: ::c_int
) -> bool
{
1417 pub {const}
fn WSTOPSIG(status
: ::c_int
) -> ::c_int
{
1421 pub {const}
fn WIFSTOPPED(status
: ::c_int
) -> bool
{
1422 (status
& 0o177) == 0o177
1427 pub fn sem_destroy(sem
: *mut sem_t
) -> ::c_int
;
1428 pub fn sem_init(sem
: *mut sem_t
, pshared
: ::c_int
, value
: ::c_uint
) -> ::c_int
;
1430 pub fn daemon(nochdir
: ::c_int
, noclose
: ::c_int
) -> ::c_int
;
1431 pub fn gettimeofday(tp
: *mut ::timeval
, tz
: *mut ::timezone
) -> ::c_int
;
1434 addr
: *mut ::sockaddr
,
1435 addrlen
: *mut ::socklen_t
,
1438 pub fn chflags(path
: *const ::c_char
, flags
: ::c_ulong
) -> ::c_int
;
1441 path
: *const ::c_char
,
1446 pub fn clock_getres(clk_id
: ::clockid_t
, tp
: *mut ::timespec
) -> ::c_int
;
1447 pub fn clock_gettime(clk_id
: ::clockid_t
, tp
: *mut ::timespec
) -> ::c_int
;
1448 pub fn clock_settime(clk_id
: ::clockid_t
, tp
: *const ::timespec
) -> ::c_int
;
1449 pub fn clock_getcpuclockid(pid
: ::pid_t
, clk_id
: *mut ::clockid_t
) -> ::c_int
;
1451 pub fn pthread_getcpuclockid(thread
: ::pthread_t
, clk_id
: *mut ::clockid_t
) -> ::c_int
;
1453 pub fn dirfd(dirp
: *mut ::DIR
) -> ::c_int
;
1454 pub fn duplocale(base
: ::locale_t
) -> ::locale_t
;
1456 pub fn fchflags(fd
: ::c_int
, flags
: ::c_ulong
) -> ::c_int
;
1459 argv
: *const *const ::c_char
,
1460 envp
: *const *const ::c_char
,
1462 pub fn futimens(fd
: ::c_int
, times
: *const ::timespec
) -> ::c_int
;
1463 pub fn getdomainname(name
: *mut ::c_char
, len
: ::c_int
) -> ::c_int
;
1468 result
: *mut *mut ::group
,
1474 result
: *mut *mut ::passwd
,
1476 pub fn getgrouplist(
1477 name
: *const ::c_char
,
1479 groups
: *mut ::gid_t
,
1480 ngroups
: *mut ::c_int
,
1483 sa
: *const ::sockaddr
,
1485 host
: *mut ::c_char
,
1487 serv
: *mut ::c_char
,
1491 pub fn getpriority(which
: ::c_int
, who
: ::c_int
) -> ::c_int
;
1492 pub fn getresgid(rgid
: *mut ::gid_t
, egid
: *mut ::gid_t
, sgid
: *mut ::gid_t
) -> ::c_int
;
1493 pub fn getresuid(ruid
: *mut ::uid_t
, euid
: *mut ::uid_t
, suid
: *mut ::uid_t
) -> ::c_int
;
1494 pub fn getutxent() -> *mut utmpx
;
1495 pub fn getutxid(ut
: *const utmpx
) -> *mut utmpx
;
1496 pub fn getutxline(ut
: *const utmpx
) -> *mut utmpx
;
1497 pub fn initgroups(name
: *const ::c_char
, basegid
: ::gid_t
) -> ::c_int
;
1499 all(target_os
= "freebsd", any(freebsd11
, freebsd10
)),
1500 link_name
= "kevent@FBSD_1.0"
1504 changelist
: *const ::kevent
,
1506 eventlist
: *mut ::kevent
,
1508 timeout
: *const ::timespec
,
1510 pub fn lchflags(path
: *const ::c_char
, flags
: ::c_ulong
) -> ::c_int
;
1511 pub fn lutimes(file
: *const ::c_char
, times
: *const ::timeval
) -> ::c_int
;
1512 pub fn memrchr(cx
: *const ::c_void
, c
: ::c_int
, n
: ::size_t
) -> *mut ::c_void
;
1513 pub fn mkfifoat(dirfd
: ::c_int
, pathname
: *const ::c_char
, mode
: ::mode_t
) -> ::c_int
;
1515 all(target_os
= "freebsd", any(freebsd11
, freebsd10
)),
1516 link_name
= "mknodat@FBSD_1.1"
1520 pathname
: *const ::c_char
,
1524 pub fn mincore(addr
: *const ::c_void
, len
: ::size_t
, vec
: *mut ::c_char
) -> ::c_int
;
1525 pub fn newlocale(mask
: ::c_int
, locale
: *const ::c_char
, base
: ::locale_t
) -> ::locale_t
;
1526 pub fn nl_langinfo_l(item
: ::nl_item
, locale
: ::locale_t
) -> *mut ::c_char
;
1527 pub fn pipe2(fds
: *mut ::c_int
, flags
: ::c_int
) -> ::c_int
;
1528 pub fn posix_fallocate(fd
: ::c_int
, offset
: ::off_t
, len
: ::off_t
) -> ::c_int
;
1529 pub fn posix_fadvise(fd
: ::c_int
, offset
: ::off_t
, len
: ::off_t
, advise
: ::c_int
) -> ::c_int
;
1533 timeout
: *const ::timespec
,
1534 sigmask
: *const sigset_t
,
1536 pub fn preadv(fd
: ::c_int
, iov
: *const ::iovec
, iovcnt
: ::c_int
, offset
: ::off_t
) -> ::ssize_t
;
1537 pub fn pthread_attr_get_np(tid
: ::pthread_t
, attr
: *mut ::pthread_attr_t
) -> ::c_int
;
1538 pub fn pthread_attr_getguardsize(
1539 attr
: *const ::pthread_attr_t
,
1540 guardsize
: *mut ::size_t
,
1542 pub fn pthread_attr_getstack(
1543 attr
: *const ::pthread_attr_t
,
1544 stackaddr
: *mut *mut ::c_void
,
1545 stacksize
: *mut ::size_t
,
1547 pub fn pthread_condattr_getclock(
1548 attr
: *const pthread_condattr_t
,
1549 clock_id
: *mut clockid_t
,
1551 pub fn pthread_condattr_getpshared(
1552 attr
: *const pthread_condattr_t
,
1553 pshared
: *mut ::c_int
,
1555 pub fn pthread_condattr_setclock(
1556 attr
: *mut pthread_condattr_t
,
1557 clock_id
: ::clockid_t
,
1559 pub fn pthread_condattr_setpshared(attr
: *mut pthread_condattr_t
, pshared
: ::c_int
) -> ::c_int
;
1560 pub fn pthread_main_np() -> ::c_int
;
1561 pub fn pthread_mutex_timedlock(
1562 lock
: *mut pthread_mutex_t
,
1563 abstime
: *const ::timespec
,
1565 pub fn pthread_mutexattr_getpshared(
1566 attr
: *const pthread_mutexattr_t
,
1567 pshared
: *mut ::c_int
,
1569 pub fn pthread_mutexattr_setpshared(
1570 attr
: *mut pthread_mutexattr_t
,
1573 pub fn pthread_rwlockattr_getpshared(
1574 attr
: *const pthread_rwlockattr_t
,
1577 pub fn pthread_rwlockattr_setpshared(attr
: *mut pthread_rwlockattr_t
, val
: ::c_int
) -> ::c_int
;
1578 pub fn pthread_barrierattr_init(attr
: *mut ::pthread_barrierattr_t
) -> ::c_int
;
1579 pub fn pthread_barrierattr_destroy(attr
: *mut ::pthread_barrierattr_t
) -> ::c_int
;
1580 pub fn pthread_barrierattr_getpshared(
1581 attr
: *const ::pthread_barrierattr_t
,
1582 shared
: *mut ::c_int
,
1584 pub fn pthread_barrierattr_setpshared(
1585 attr
: *mut ::pthread_barrierattr_t
,
1588 pub fn pthread_barrier_init(
1589 barrier
: *mut pthread_barrier_t
,
1590 attr
: *const ::pthread_barrierattr_t
,
1593 pub fn pthread_barrier_destroy(barrier
: *mut pthread_barrier_t
) -> ::c_int
;
1594 pub fn pthread_barrier_wait(barrier
: *mut pthread_barrier_t
) -> ::c_int
;
1595 pub fn pthread_get_name_np(tid
: ::pthread_t
, name
: *mut ::c_char
, len
: ::size_t
);
1596 pub fn pthread_set_name_np(tid
: ::pthread_t
, name
: *const ::c_char
);
1597 pub fn ptrace(request
: ::c_int
, pid
: ::pid_t
, addr
: *mut ::c_char
, data
: ::c_int
) -> ::c_int
;
1598 pub fn utrace(addr
: *const ::c_void
, len
: ::size_t
) -> ::c_int
;
1599 pub fn pututxline(ut
: *const utmpx
) -> *mut utmpx
;
1600 pub fn pwritev(fd
: ::c_int
, iov
: *const ::iovec
, iovcnt
: ::c_int
, offset
: ::off_t
)
1602 pub fn querylocale(mask
: ::c_int
, loc
: ::locale_t
) -> *const ::c_char
;
1603 pub fn rtprio(function
: ::c_int
, pid
: ::pid_t
, rtp
: *mut rtprio
) -> ::c_int
;
1604 pub fn sched_rr_get_interval(pid
: ::pid_t
, t
: *mut ::timespec
) -> ::c_int
;
1605 pub fn sched_getparam(pid
: ::pid_t
, param
: *mut sched_param
) -> ::c_int
;
1606 pub fn sched_setparam(pid
: ::pid_t
, param
: *const sched_param
) -> ::c_int
;
1607 pub fn sched_getscheduler(pid
: ::pid_t
) -> ::c_int
;
1608 pub fn sched_setscheduler(
1611 param
: *const ::sched_param
,
1613 pub fn sem_getvalue(sem
: *mut sem_t
, sval
: *mut ::c_int
) -> ::c_int
;
1614 pub fn sem_timedwait(sem
: *mut sem_t
, abstime
: *const ::timespec
) -> ::c_int
;
1620 hdtr
: *mut ::sf_hdtr
,
1621 sbytes
: *mut ::off_t
,
1624 pub fn setdomainname(name
: *const ::c_char
, len
: ::c_int
) -> ::c_int
;
1625 pub fn sethostname(name
: *const ::c_char
, len
: ::c_int
) -> ::c_int
;
1626 pub fn setpriority(which
: ::c_int
, who
: ::c_int
, prio
: ::c_int
) -> ::c_int
;
1627 pub fn setresgid(rgid
: ::gid_t
, egid
: ::gid_t
, sgid
: ::gid_t
) -> ::c_int
;
1628 pub fn setresuid(ruid
: ::uid_t
, euid
: ::uid_t
, suid
: ::uid_t
) -> ::c_int
;
1629 pub fn settimeofday(tv
: *const ::timeval
, tz
: *const ::timezone
) -> ::c_int
;
1631 pub fn shm_open(name
: *const ::c_char
, oflag
: ::c_int
, mode
: ::mode_t
) -> ::c_int
;
1632 pub fn sigtimedwait(
1633 set
: *const sigset_t
,
1634 info
: *mut siginfo_t
,
1635 timeout
: *const ::timespec
,
1637 pub fn sigwaitinfo(set
: *const sigset_t
, info
: *mut siginfo_t
) -> ::c_int
;
1639 name
: *const ::c_int
,
1641 oldp
: *mut ::c_void
,
1642 oldlenp
: *mut ::size_t
,
1643 newp
: *const ::c_void
,
1646 pub fn sysctlbyname(
1647 name
: *const ::c_char
,
1648 oldp
: *mut ::c_void
,
1649 oldlenp
: *mut ::size_t
,
1650 newp
: *const ::c_void
,
1653 pub fn sysctlnametomib(
1654 name
: *const ::c_char
,
1656 sizep
: *mut ::size_t
,
1658 pub fn uselocale(loc
: ::locale_t
) -> ::locale_t
;
1661 path
: *const ::c_char
,
1662 times
: *const ::timespec
,
1666 pub fn ntp_adjtime(buf
: *mut timex
) -> ::c_int
;
1667 pub fn ntp_gettime(buf
: *mut ntptimeval
) -> ::c_int
;
1669 // #include <link.h>
1670 pub fn dl_iterate_phdr(
1672 unsafe extern "C" fn(
1673 info
: *mut dl_phdr_info
,
1675 data
: *mut ::c_void
,
1678 data
: *mut ::c_void
,
1681 pub fn iconv_open(tocode
: *const ::c_char
, fromcode
: *const ::c_char
) -> iconv_t
;
1684 inbuf
: *mut *mut ::c_char
,
1685 inbytesleft
: *mut ::size_t
,
1686 outbuf
: *mut *mut ::c_char
,
1687 outbytesleft
: *mut ::size_t
,
1689 pub fn iconv_close(cd
: iconv_t
) -> ::c_int
;
1691 // Added in `FreeBSD` 11.0
1692 // Added in `DragonFly BSD` 5.4
1693 pub fn explicit_bzero(s
: *mut ::c_void
, len
: ::size_t
);
1694 // ISO/IEC 9899:2011 ("ISO C11") K.3.7.4.1
1695 pub fn memset_s(s
: *mut ::c_void
, smax
: ::size_t
, c
: ::c_int
, n
: ::size_t
) -> ::c_int
;
1696 pub fn gethostid() -> ::c_long
;
1697 pub fn sethostid(hostid
: ::c_long
);
1700 #[link(name = "rt")]
1702 pub fn mq_close(mqd
: ::mqd_t
) -> ::c_int
;
1703 pub fn mq_getattr(mqd
: ::mqd_t
, attr
: *mut ::mq_attr
) -> ::c_int
;
1704 pub fn mq_notify(mqd
: ::mqd_t
, notification
: *const ::sigevent
) -> ::c_int
;
1705 pub fn mq_open(name
: *const ::c_char
, oflag
: ::c_int
, ...) -> ::mqd_t
;
1708 msg_ptr
: *mut ::c_char
,
1710 msg_prio
: *mut ::c_uint
,
1714 msg_ptr
: *const ::c_char
,
1718 pub fn mq_setattr(mqd
: ::mqd_t
, newattr
: *const ::mq_attr
, oldattr
: *mut ::mq_attr
) -> ::c_int
;
1719 pub fn mq_timedreceive(
1721 msg_ptr
: *mut ::c_char
,
1723 msg_prio
: *mut ::c_uint
,
1724 abs_timeout
: *const ::timespec
,
1726 pub fn mq_timedsend(
1728 msg_ptr
: *const ::c_char
,
1731 abs_timeout
: *const ::timespec
,
1733 pub fn mq_unlink(name
: *const ::c_char
) -> ::c_int
;
1736 #[link(name = "util")]
1739 amaster
: *mut ::c_int
,
1740 aslave
: *mut ::c_int
,
1741 name
: *mut ::c_char
,
1742 termp
: *mut termios
,
1743 winp
: *mut ::winsize
,
1746 amaster
: *mut ::c_int
,
1747 name
: *mut ::c_char
,
1748 termp
: *mut termios
,
1749 winp
: *mut ::winsize
,
1751 pub fn login_tty(fd
: ::c_int
) -> ::c_int
;
1753 stream
: *mut ::FILE
,
1755 lineno
: *mut ::size_t
,
1756 delim
: *const ::c_char
,
1761 #[link(name = "execinfo")]
1763 pub fn backtrace(addrlist
: *mut *mut ::c_void
, len
: ::size_t
) -> ::size_t
;
1764 pub fn backtrace_symbols(addrlist
: *const *mut ::c_void
, len
: ::size_t
) -> *mut *mut ::c_char
;
1765 pub fn backtrace_symbols_fd(
1766 addrlist
: *const *mut ::c_void
,
1773 if #[cfg(target_os = "freebsd")] {
1775 pub use self::freebsd
::*;
1776 } else if #[cfg(target_os = "dragonfly")] {
1778 pub use self::dragonfly
::*;