3 * Copyright (C) 2008-2009 Jürg Billeter
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20 * Jürg Billeter <j@bitron.ch>
24 [CCode (cname = "bool", cheader_filename = "stdbool.h", default_value = "false")]
29 [CCode (cname = "char", default_value = "\'\\0\'")]
30 [IntegerType (rank = 2, min = 0, max = 127)]
34 [CCode (cname = "unsigned char", default_value = "\'\\0\'")]
35 [IntegerType (rank = 3, min = 0, max = 255)]
39 [CCode (cname = "int", default_value = "0")]
40 [IntegerType (rank = 6)]
44 [CCode (cname = "unsigned int", default_value = "0U")]
45 [IntegerType (rank = 7)]
49 [CCode (cname = "short", default_value = "0")]
50 [IntegerType (rank = 4, min = -32768, max = 32767)]
54 [CCode (cname = "unsigned short", default_value = "0U")]
55 [IntegerType (rank = 5, min = 0, max = 65535)]
56 public struct ushort {
59 [CCode (cname = "long", default_value = "0L")]
60 [IntegerType (rank = 8)]
64 [CCode (cname = "unsigned long", default_value = "0UL")]
65 [IntegerType (rank = 9)]
69 [CCode (cname = "size_t", cheader_filename = "sys/types.h", default_value = "0UL")]
70 [IntegerType (rank = 9)]
71 public struct size_t {
74 [CCode (cname = "ssize_t", cheader_filename = "sys/types.h", default_value = "0L")]
75 [IntegerType (rank = 8)]
76 public struct ssize_t {
79 [CCode (cname = "int8_t", cheader_filename = "stdint.h", default_value = "0")]
80 [IntegerType (rank = 1, min = -128, max = 127)]
84 [CCode (cname = "uint8_t", cheader_filename = "stdint.h", default_value = "0U")]
85 [IntegerType (rank = 3, min = 0, max = 255)]
89 [CCode (cname = "int16_t", cheader_filename = "stdint.h", default_value = "0")]
90 [IntegerType (rank = 4, min = -32768, max = 32767)]
94 [CCode (cname = "uint16_t", cheader_filename = "stdint.h", default_value = "0U")]
95 [IntegerType (rank = 5, min = 0, max = 65535)]
96 public struct uint16 {
99 [CCode (cname = "int32_t", cheader_filename = "stdint.h", default_value = "0")]
100 [IntegerType (rank = 6)]
101 public struct int32 {
104 [CCode (cname = "uint32_t", cheader_filename = "stdint.h", default_value = "0U")]
105 [IntegerType (rank = 7)]
106 public struct uint32 {
109 [CCode (cname = "int64_t", cheader_filename = "stdint.h", default_value = "0LL")]
110 [IntegerType (rank = 10)]
111 public struct int64 {
114 [CCode (cname = "uint64_t", cheader_filename = "stdint.h", default_value = "0ULL")]
115 [IntegerType (rank = 11)]
116 public struct uint64 {
119 [CCode (cname = "float", default_value = "0.0F")]
120 [FloatingType (rank = 1)]
121 public struct float {
124 [CCode (cname = "double", default_value = "0.0")]
125 [FloatingType (rank = 2)]
126 public struct double {
129 [CCode (cheader_filename = "time.h")]
130 [IntegerType (rank = 8)]
131 public struct time_t {
132 [CCode (cname = "time")]
138 [CCode (cname = "char", const_cname = "const char", copy_function = "strdup", free_function = "free", cheader_filename = "stdlib.h,string.h")]
139 public class string {
140 [CCode (cname="atoi")]
142 [CCode (cname="atol")]
143 public long to_long();
144 [CCode (cname="atoll")]
145 public int64 to_int64();
146 [CCode (cname="strlen")]
150 [CCode (cname="printf", cheader_filename = "stdio.h")]
152 public void print (string format,...);
156 [CCode (cprefix = "", lower_case_cprefix = "")]
158 [CCode (cheader_filename = "assert.h")]
159 public void assert (bool expression);
161 [CCode (cheader_filename = "ctype.h")]
162 public bool isalnum (int c);
163 [CCode (cheader_filename = "ctype.h")]
164 public bool isalpha (int c);
165 [CCode (cheader_filename = "ctype.h")]
166 public bool isascii (int c);
167 [CCode (cheader_filename = "ctype.h")]
168 public bool iscntrl (int c);
169 [CCode (cheader_filename = "ctype.h")]
170 public bool isdigit (int c);
171 [CCode (cheader_filename = "ctype.h")]
172 public bool isgraph (int c);
173 [CCode (cheader_filename = "ctype.h")]
174 public bool islower (int c);
175 [CCode (cheader_filename = "ctype.h")]
176 public bool isprint (int c);
177 [CCode (cheader_filename = "ctype.h")]
178 public bool ispunct (int c);
179 [CCode (cheader_filename = "ctype.h")]
180 public bool isspace (int c);
181 [CCode (cheader_filename = "ctype.h")]
182 public bool isupper (int c);
183 [CCode (cheader_filename = "ctype.h")]
184 public bool isxdigit (int c);
185 [CCode (cheader_filename = "ctype.h")]
186 public int toascii (int c);
187 [CCode (cheader_filename = "ctype.h")]
188 public int tolower (int c);
189 [CCode (cheader_filename = "ctype.h")]
190 public int toupper (int c);
193 [CCode (cname = "struct dirent", cheader_filename = "dirent.h")]
194 public class DirEnt {
197 public ushort d_reclen;
199 public char d_name[256];
203 [CCode (cname = "DIR", free_function = "closedir", cheader_filename = "dirent.h")]
207 [CCode (cheader_filename = "dirent.h")]
208 public int dirfd (Dir dir);
209 [CCode (cheader_filename = "dirent.h")]
210 public Dir? opendir (string filename);
211 [CCode (cheader_filename = "dirent.h")]
212 public Dir? fdopendir (int fd);
213 [CCode (cheader_filename = "dirent.h")]
214 public unowned DirEnt? readdir (Dir dir);
215 [CCode (cheader_filename = "dirent.h")]
216 public void rewinddir (Dir dir);
217 [CCode (cheader_filename = "dirent.h")]
218 public void seekdir (Dir dir, long pos);
219 [CCode (cheader_filename = "dirent.h")]
220 public long telldir (Dir dir);
222 [CCode (cheader_filename = "errno.h")]
224 [CCode (cheader_filename = "errno.h")]
225 public const int E2BIG;
226 [CCode (cheader_filename = "errno.h")]
227 public const int EACCES;
228 [CCode (cheader_filename = "errno.h")]
229 public const int EADDRINUSE;
230 [CCode (cheader_filename = "errno.h")]
231 public const int EADDRNOTAVAIL;
232 [CCode (cheader_filename = "errno.h")]
233 public const int EAFNOSUPPORT;
234 [CCode (cheader_filename = "errno.h")]
235 public const int EAGAIN;
236 [CCode (cheader_filename = "errno.h")]
237 public const int EALREADY;
238 [CCode (cheader_filename = "errno.h")]
239 public const int EBADF;
240 [CCode (cheader_filename = "errno.h")]
241 public const int EBADMSG;
242 [CCode (cheader_filename = "errno.h")]
243 public const int EBUSY;
244 [CCode (cheader_filename = "errno.h")]
245 public const int ECANCELED;
246 [CCode (cheader_filename = "errno.h")]
247 public const int ECHILD;
248 [CCode (cheader_filename = "errno.h")]
249 public const int ECONNABORTED;
250 [CCode (cheader_filename = "errno.h")]
251 public const int ECONNREFUSED;
252 [CCode (cheader_filename = "errno.h")]
253 public const int ECONNRESET;
254 [CCode (cheader_filename = "errno.h")]
255 public const int EDEADLK;
256 [CCode (cheader_filename = "errno.h")]
257 public const int EDESTADDRREQ;
258 [CCode (cheader_filename = "errno.h")]
259 public const int EDOM;
260 [CCode (cheader_filename = "errno.h")]
261 public const int EDQUOT;
262 [CCode (cheader_filename = "errno.h")]
263 public const int EEXIST;
264 [CCode (cheader_filename = "errno.h")]
265 public const int EFAULT;
266 [CCode (cheader_filename = "errno.h")]
267 public const int EFBIG;
268 [CCode (cheader_filename = "errno.h")]
269 public const int EHOSTUNREACH;
270 [CCode (cheader_filename = "errno.h")]
271 public const int EIDRM;
272 [CCode (cheader_filename = "errno.h")]
273 public const int EILSEQ;
274 [CCode (cheader_filename = "errno.h")]
275 public const int EINPROGRESS;
276 [CCode (cheader_filename = "errno.h")]
277 public const int EINTR;
278 [CCode (cheader_filename = "errno.h")]
279 public const int EINVAL;
280 [CCode (cheader_filename = "errno.h")]
281 public const int EIO;
282 [CCode (cheader_filename = "errno.h")]
283 public const int EISCONN;
284 [CCode (cheader_filename = "errno.h")]
285 public const int EISDIR;
286 [CCode (cheader_filename = "errno.h")]
287 public const int ELOOP;
288 [CCode (cheader_filename = "errno.h")]
289 public const int EMFILE;
290 [CCode (cheader_filename = "errno.h")]
291 public const int EMLINK;
292 [CCode (cheader_filename = "errno.h")]
293 public const int EMSGSIZE;
294 [CCode (cheader_filename = "errno.h")]
295 public const int EMULTIHOP;
296 [CCode (cheader_filename = "errno.h")]
297 public const int ENAMETOOLONG;
298 [CCode (cheader_filename = "errno.h")]
299 public const int ENETDOWN;
300 [CCode (cheader_filename = "errno.h")]
301 public const int ENETRESET;
302 [CCode (cheader_filename = "errno.h")]
303 public const int ENETUNREACH;
304 [CCode (cheader_filename = "errno.h")]
305 public const int ENFILE;
306 [CCode (cheader_filename = "errno.h")]
307 public const int ENOBUFS;
308 [CCode (cheader_filename = "errno.h")]
309 public const int ENODATA;
310 [CCode (cheader_filename = "errno.h")]
311 public const int ENODEV;
312 [CCode (cheader_filename = "errno.h")]
313 public const int ENOENT;
314 [CCode (cheader_filename = "errno.h")]
315 public const int ENOEXEC;
316 [CCode (cheader_filename = "errno.h")]
317 public const int ENOLCK;
318 [CCode (cheader_filename = "errno.h")]
319 public const int ENOLINK;
320 [CCode (cheader_filename = "errno.h")]
321 public const int ENOMEM;
322 [CCode (cheader_filename = "errno.h")]
323 public const int ENOMSG;
324 [CCode (cheader_filename = "errno.h")]
325 public const int ENOPROTOOPT;
326 [CCode (cheader_filename = "errno.h")]
327 public const int ENOSPC;
328 [CCode (cheader_filename = "errno.h")]
329 public const int ENOSR;
330 [CCode (cheader_filename = "errno.h")]
331 public const int ENOSTR;
332 [CCode (cheader_filename = "errno.h")]
333 public const int ENOSYS;
334 [CCode (cheader_filename = "errno.h")]
335 public const int ENOTCONN;
336 [CCode (cheader_filename = "errno.h")]
337 public const int ENOTDIR;
338 [CCode (cheader_filename = "errno.h")]
339 public const int ENOTEMPTY;
340 [CCode (cheader_filename = "errno.h")]
341 public const int ENOTSOCK;
342 [CCode (cheader_filename = "errno.h")]
343 public const int ENOTSUP;
344 [CCode (cheader_filename = "errno.h")]
345 public const int ENOTTY;
346 [CCode (cheader_filename = "errno.h")]
347 public const int ENXIO;
348 [CCode (cheader_filename = "errno.h")]
349 public const int EOPNOTSUPP;
350 [CCode (cheader_filename = "errno.h")]
351 public const int EOVERFLOW;
352 [CCode (cheader_filename = "errno.h")]
353 public const int EPERM;
354 [CCode (cheader_filename = "errno.h")]
355 public const int EPIPE;
356 [CCode (cheader_filename = "errno.h")]
357 public const int EPROTO;
358 [CCode (cheader_filename = "errno.h")]
359 public const int EPROTONOSUPPORT;
360 [CCode (cheader_filename = "errno.h")]
361 public const int EPROTOTYPE;
362 [CCode (cheader_filename = "errno.h")]
363 public const int ERANGE;
364 [CCode (cheader_filename = "errno.h")]
365 public const int EROFS;
366 [CCode (cheader_filename = "errno.h")]
367 public const int ESPIPE;
368 [CCode (cheader_filename = "errno.h")]
369 public const int ESRCH;
370 [CCode (cheader_filename = "errno.h")]
371 public const int ESTALE;
372 [CCode (cheader_filename = "errno.h")]
373 public const int ETIME;
374 [CCode (cheader_filename = "errno.h")]
375 public const int ETIMEDOUT;
376 [CCode (cheader_filename = "errno.h")]
377 public const int ETXTBSY;
378 [CCode (cheader_filename = "errno.h")]
379 public const int EWOULDBLOCK;
380 [CCode (cheader_filename = "errno.h")]
381 public const int EXDEV;
383 [CCode (cheader_filename = "fcntl.h")]
384 public const int F_DUPFD;
385 [CCode (cheader_filename = "fcntl.h")]
386 public const int F_GETFD;
387 [CCode (cheader_filename = "fcntl.h")]
388 public const int F_SETFD;
389 [CCode (cheader_filename = "fcntl.h")]
390 public const int F_GETFL;
391 [CCode (cheader_filename = "fcntl.h")]
392 public const int F_SETFL;
393 [CCode (cheader_filename = "fcntl.h")]
394 public const int F_GETLK;
395 [CCode (cheader_filename = "fcntl.h")]
396 public const int F_SETLK;
397 [CCode (cheader_filename = "fcntl.h")]
398 public const int F_SETLKW;
399 [CCode (cheader_filename = "fcntl.h")]
400 public const int F_GETOWN;
401 [CCode (cheader_filename = "fcntl.h")]
402 public const int F_SETOWN;
403 [CCode (cheader_filename = "fcntl.h")]
404 public const int FD_CLOEXEC;
405 [CCode (cheader_filename = "fcntl.h")]
406 public const int F_RDLCK;
407 [CCode (cheader_filename = "fcntl.h")]
408 public const int F_UNLCK;
409 [CCode (cheader_filename = "fcntl.h")]
410 public const int F_WRLCK;
411 [CCode (cheader_filename = "fcntl.h")]
412 public const int O_CREAT;
413 [CCode (cheader_filename = "fcntl.h")]
414 public const int O_EXCL;
415 [CCode (cheader_filename = "fcntl.h")]
416 public const int O_NOCTTY;
417 [CCode (cheader_filename = "fcntl.h")]
418 public const int O_TRUNC;
419 [CCode (cheader_filename = "fcntl.h")]
420 public const int O_APPEND;
421 [CCode (cheader_filename = "fcntl.h")]
422 public const int O_DSYNC;
423 [CCode (cheader_filename = "fcntl.h")]
424 public const int O_NONBLOCK;
425 [CCode (cheader_filename = "fcntl.h")]
426 public const int O_RSYNC;
427 [CCode (cheader_filename = "fcntl.h")]
428 public const int O_SYNC;
429 [CCode (cheader_filename = "fcntl.h")]
430 public const int O_ACCMODE;
431 [CCode (cheader_filename = "fcntl.h")]
432 public const int O_RDONLY;
433 [CCode (cheader_filename = "fcntl.h")]
434 public const int O_RDWR;
435 [CCode (cheader_filename = "fcntl.h")]
436 public const int O_WRONLY;
437 [CCode (cheader_filename = "fcntl.h")]
438 public const int POSIX_FADV_NORMAL;
439 [CCode (cheader_filename = "fcntl.h")]
440 public const int POSIX_FADV_SEQUENTIAL;
441 [CCode (cheader_filename = "fcntl.h")]
442 public const int POSIX_FADV_RANDOM;
443 [CCode (cheader_filename = "fcntl.h")]
444 public const int POSIX_FADV_WILLNEED;
445 [CCode (cheader_filename = "fcntl.h")]
446 public const int POSIX_FADV_DONTNEED;
447 [CCode (cheader_filename = "fcntl.h")]
448 public const int POSIX_FADV_NOREUSE;
449 [CCode (cheader_filename = "fcntl.h")]
450 public int creat (string path, mode_t mode);
451 [CCode (cheader_filename = "fcntl.h")]
452 public int fcntl (int fd, int cmd, ...);
453 [CCode (cheader_filename = "fcntl.h")]
454 public int open (string path, int oflag, mode_t mode=0);
455 [CCode (cheader_filename = "fcntl.h")]
456 public int posix_fadvise (int fd, long offset, long len, int advice);
457 [CCode (cheader_filename = "fcntl.h")]
458 public int posix_fallocate (int fd, long offset, long len);
461 [CCode (cname = "struct group", cheader_filename = "grp.h")]
463 public string gr_name;
464 public string gr_passwd;
466 public string[] gr_mem;
468 [CCode (cheader_filename = "grp.h")]
469 public void endgrent ();
470 public unowned Group? getgrent ();
471 public void setgrent ();
473 [CCode (cheader_filename = "arpa/inet.h")]
474 public uint32 inet_addr (string host);
475 [CCode (cheader_filename = "arpa/inet.h")]
476 public unowned string inet_ntoa (InAddr addr);
477 [CCode (cheader_filename = "arpa/inet.h")]
478 public uint32 htonl (uint32 hostlong);
479 [CCode (cheader_filename = "arpa/inet.h")]
480 public uint32 ntohl (uint32 netlong);
481 [CCode (cheader_filename = "arpa/inet.h")]
482 public uint16 htons (uint16 hostshort);
483 [CCode (cheader_filename = "arpa/inet.h")]
484 public uint16 ntohs (uint16 netshort);
486 [CCode (cheader_filename = "math.h")]
487 public double acos (double x);
488 [CCode (cheader_filename = "math.h")]
489 public float acosf (float x);
490 [CCode (cheader_filename = "math.h")]
491 public double asin (double x);
492 [CCode (cheader_filename = "math.h")]
493 public float asinf (float x);
494 [CCode (cheader_filename = "math.h")]
495 public double atan (double x);
496 [CCode (cheader_filename = "math.h")]
497 public float atanf (float x);
498 [CCode (cheader_filename = "math.h")]
499 public double atan2 (double y, double x);
500 [CCode (cheader_filename = "math.h")]
501 public float atan2f (float y, float x);
502 [CCode (cheader_filename = "math.h")]
503 public double cos (double x);
504 [CCode (cheader_filename = "math.h")]
505 public float cosf (float x);
506 [CCode (cheader_filename = "math.h")]
507 public double sin (double x);
508 [CCode (cheader_filename = "math.h")]
509 public float sinf (float x);
510 [CCode (cheader_filename = "math.h")]
511 public double tan (double x);
512 [CCode (cheader_filename = "math.h")]
513 public float tanf (float x);
514 [CCode (cheader_filename = "math.h")]
515 public double cosh (double x);
516 [CCode (cheader_filename = "math.h")]
517 public float coshf (float x);
518 [CCode (cheader_filename = "math.h")]
519 public double sinh (double x);
520 [CCode (cheader_filename = "math.h")]
521 public float sinhf (float x);
522 [CCode (cheader_filename = "math.h")]
523 public double tanh (double x);
524 [CCode (cheader_filename = "math.h")]
525 public float tanhf (float x);
526 [CCode (cheader_filename = "math.h")]
527 public void sincos (double x, out double sinx, out double cosx);
528 [CCode (cheader_filename = "math.h")]
529 public void sincosf (float x, out float sinx, out float cosx);
530 [CCode (cheader_filename = "math.h")]
531 public double acosh (double x);
532 [CCode (cheader_filename = "math.h")]
533 public float acoshf (float x);
534 [CCode (cheader_filename = "math.h")]
535 public double asinh (double x);
536 [CCode (cheader_filename = "math.h")]
537 public float asinhf (float x);
538 [CCode (cheader_filename = "math.h")]
539 public double atanh (double x);
540 [CCode (cheader_filename = "math.h")]
541 public float atanhf (float x);
542 [CCode (cheader_filename = "math.h")]
543 public double exp (double x);
544 [CCode (cheader_filename = "math.h")]
545 public float expf (float x);
546 [CCode (cheader_filename = "math.h")]
547 public double frexp (double x, out int exponent);
548 [CCode (cheader_filename = "math.h")]
549 public float frexpf (float x, out int exponent);
550 [CCode (cheader_filename = "math.h")]
551 public double ldexp (double x, int exponent);
552 [CCode (cheader_filename = "math.h")]
553 public float ldexpf (float x, int exponent);
554 [CCode (cheader_filename = "math.h")]
555 public double log (double x);
556 [CCode (cheader_filename = "math.h")]
557 public float logf (float x);
558 [CCode (cheader_filename = "math.h")]
559 public double log10 (double x);
560 [CCode (cheader_filename = "math.h")]
561 public float log10f (float x);
562 [CCode (cheader_filename = "math.h")]
563 public double modf (double x, out double iptr);
564 [CCode (cheader_filename = "math.h")]
565 public float modff (float x, out float iptr);
566 [CCode (cheader_filename = "math.h")]
567 public double exp10 (double x);
568 [CCode (cheader_filename = "math.h")]
569 public float exp10f (float x);
570 [CCode (cheader_filename = "math.h")]
571 public double pow10 (double x);
572 [CCode (cheader_filename = "math.h")]
573 public float pow10f (float x);
574 [CCode (cheader_filename = "math.h")]
575 public double expm1 (double x);
576 [CCode (cheader_filename = "math.h")]
577 public float expm1f (float x);
578 [CCode (cheader_filename = "math.h")]
579 public double log1p (double x);
580 [CCode (cheader_filename = "math.h")]
581 public float log1pf (float x);
582 [CCode (cheader_filename = "math.h")]
583 public double logb (double x);
584 [CCode (cheader_filename = "math.h")]
585 public float logbf (float x);
586 [CCode (cheader_filename = "math.h")]
587 public double exp2 (double x);
588 [CCode (cheader_filename = "math.h")]
589 public float exp2f (float x);
590 [CCode (cheader_filename = "math.h")]
591 public double log2 (double x);
592 [CCode (cheader_filename = "math.h")]
593 public float log2f (float x);
594 [CCode (cheader_filename = "math.h")]
595 public double pow (double x, double y);
596 [CCode (cheader_filename = "math.h")]
597 public float powf (float x, float y);
598 [CCode (cheader_filename = "math.h")]
599 public double sqrt (double x);
600 [CCode (cheader_filename = "math.h")]
601 public float sqrtf (float x);
602 [CCode (cheader_filename = "math.h")]
603 public double hypot (double x, double y);
604 [CCode (cheader_filename = "math.h")]
605 public float hypotf (float x, float y);
606 [CCode (cheader_filename = "math.h")]
607 public double cbrt (double x);
608 [CCode (cheader_filename = "math.h")]
609 public float cbrtf (float x);
610 [CCode (cheader_filename = "math.h")]
611 public double ceil (double x);
612 [CCode (cheader_filename = "math.h")]
613 public float ceilf (float x);
614 [CCode (cheader_filename = "math.h")]
615 public double fabs (double x);
616 [CCode (cheader_filename = "math.h")]
617 public float fabsf (float x);
618 [CCode (cheader_filename = "math.h")]
619 public double floor (double x);
620 [CCode (cheader_filename = "math.h")]
621 public float floorf (float x);
622 [CCode (cheader_filename = "math.h")]
623 public double fmod (double x, double y);
624 [CCode (cheader_filename = "math.h")]
625 public float fmodf (float x, float y);
626 [CCode (cheader_filename = "math.h")]
627 public int isinf (double value);
628 [CCode (cheader_filename = "math.h")]
629 public int isinff (float value);
630 [CCode (cheader_filename = "math.h")]
631 public int finite (double value);
632 [CCode (cheader_filename = "math.h")]
633 public int finitef (float value);
634 [CCode (cheader_filename = "math.h")]
635 public double drem (double x, double y);
636 [CCode (cheader_filename = "math.h")]
637 public float dremf (float x, float y);
638 [CCode (cheader_filename = "math.h")]
639 public double significand (double x);
640 [CCode (cheader_filename = "math.h")]
641 public float significandf (float x);
642 [CCode (cheader_filename = "math.h")]
643 public double copysign (double x, double y);
644 [CCode (cheader_filename = "math.h")]
645 public float copysignf (float x, float y);
646 [CCode (cheader_filename = "math.h")]
647 public double nan (string tagb);
648 [CCode (cheader_filename = "math.h")]
649 public float nanf (string tagb);
650 [CCode (cheader_filename = "math.h")]
651 public int isnan (double value);
652 [CCode (cheader_filename = "math.h")]
653 public int isnanf (float value);
654 [CCode (cheader_filename = "math.h")]
655 public double j0 (double x0);
656 [CCode (cheader_filename = "math.h")]
657 public float j0f (float x0);
658 [CCode (cheader_filename = "math.h")]
659 public double j1 (double x0);
660 [CCode (cheader_filename = "math.h")]
661 public float j1f (float x0);
662 [CCode (cheader_filename = "math.h")]
663 public double jn (int x0, double x1);
664 [CCode (cheader_filename = "math.h")]
665 public float jnf (int x0, float x1);
666 [CCode (cheader_filename = "math.h")]
667 public double y0 (double x0);
668 [CCode (cheader_filename = "math.h")]
669 public float y0f (float x0);
670 [CCode (cheader_filename = "math.h")]
671 public double y1 (double x0);
672 [CCode (cheader_filename = "math.h")]
673 public float y1f (float x0);
674 [CCode (cheader_filename = "math.h")]
675 public double yn (int x0, double x1);
676 [CCode (cheader_filename = "math.h")]
677 public float ynf (int x0, float x1);
678 [CCode (cheader_filename = "math.h")]
679 public double erf (double x0);
680 [CCode (cheader_filename = "math.h")]
681 public float erff (float x0);
682 [CCode (cheader_filename = "math.h")]
683 public double erfc (double x0);
684 [CCode (cheader_filename = "math.h")]
685 public float erfcf (float x0);
686 [CCode (cheader_filename = "math.h")]
687 public double lgamma (double x0);
688 [CCode (cheader_filename = "math.h")]
689 public float lgammaf (float x0);
690 [CCode (cheader_filename = "math.h")]
691 public double tgamma (double x0);
692 [CCode (cheader_filename = "math.h")]
693 public float tgammaf (float x0);
694 [CCode (cheader_filename = "math.h")]
695 public double gamma (double x0);
696 [CCode (cheader_filename = "math.h")]
697 public float gammaf (float x0);
698 [CCode (cheader_filename = "math.h")]
699 public double lgamma_r (double x0, out int signgamp);
700 [CCode (cheader_filename = "math.h")]
701 public float lgamma_rf (float x0, out int signgamp);
702 [CCode (cheader_filename = "math.h")]
703 public double rint (double x);
704 [CCode (cheader_filename = "math.h")]
705 public float rintf (float x);
706 [CCode (cheader_filename = "math.h")]
707 public double nextafter (double x, double y);
708 [CCode (cheader_filename = "math.h")]
709 public float nextafterf (float x, float y);
710 [CCode (cheader_filename = "math.h")]
711 public double nexttoward (double x, double y);
712 [CCode (cheader_filename = "math.h")]
713 public float nexttowardf (float x, double y);
714 [CCode (cheader_filename = "math.h")]
715 public double remainder (double x, double y);
716 [CCode (cheader_filename = "math.h")]
717 public float remainderf (float x, float y);
718 [CCode (cheader_filename = "math.h")]
719 public double scalbn (double x, int n);
720 [CCode (cheader_filename = "math.h")]
721 public float scalbnf (float x, int n);
722 [CCode (cheader_filename = "math.h")]
723 public int ilogb (double x);
724 [CCode (cheader_filename = "math.h")]
725 public int ilogbf (float x);
726 [CCode (cheader_filename = "math.h")]
727 public double scalbln (double x, long n);
728 [CCode (cheader_filename = "math.h")]
729 public float scalblnf (float x, long n);
730 [CCode (cheader_filename = "math.h")]
731 public double nearbyint (double x);
732 [CCode (cheader_filename = "math.h")]
733 public float nearbyintf (float x);
734 [CCode (cheader_filename = "math.h")]
735 public double round (double x);
736 [CCode (cheader_filename = "math.h")]
737 public float roundf (float x);
738 [CCode (cheader_filename = "math.h")]
739 public double trunc (double x);
740 [CCode (cheader_filename = "math.h")]
741 public float truncf (float x);
742 [CCode (cheader_filename = "math.h")]
743 public double remquo (double x, double y, out int quo);
744 [CCode (cheader_filename = "math.h")]
745 public float remquof (float x, float y, out int quo);
746 [CCode (cheader_filename = "math.h")]
747 public long lrint (double x);
748 [CCode (cheader_filename = "math.h")]
749 public long lrintf (float x);
750 [CCode (cheader_filename = "math.h")]
751 public int64 llrint (double x);
752 [CCode (cheader_filename = "math.h")]
753 public int64 llrintf (float x);
754 [CCode (cheader_filename = "math.h")]
755 public long lround (double x);
756 [CCode (cheader_filename = "math.h")]
757 public long lroundf (float x);
758 [CCode (cheader_filename = "math.h")]
759 public int64 llround (double x);
760 [CCode (cheader_filename = "math.h")]
761 public int64 llroundf (float x);
762 [CCode (cheader_filename = "math.h")]
763 public double fdim (double x, double y);
764 [CCode (cheader_filename = "math.h")]
765 public float fdimf (float x, float y);
766 [CCode (cheader_filename = "math.h")]
767 public double fmax (double x, double y);
768 [CCode (cheader_filename = "math.h")]
769 public float fmaxf (float x, float y);
770 [CCode (cheader_filename = "math.h")]
771 public double fmin (double x, double y);
772 [CCode (cheader_filename = "math.h")]
773 public float fminf (float x, float y);
774 [CCode (cheader_filename = "math.h")]
775 public double fma (double x, double y, double z);
776 [CCode (cheader_filename = "math.h")]
777 public float fmaf (float x, float y, float z);
778 [CCode (cheader_filename = "math.h")]
779 public double scalb (double x, double n);
780 [CCode (cheader_filename = "math.h")]
781 public float scalbf (float x, float n);
783 [CCode (cheader_filename = "poll.h", cname = "struct pollfd")]
784 public struct pollfd {
790 [CCode (cheader_filename = "poll.h")]
791 public const int POLLIN;
792 [CCode (cheader_filename = "poll.h")]
793 public const int POLLPRI;
794 [CCode (cheader_filename = "poll.h")]
795 public const int POLLOUT;
796 [CCode (cheader_filename = "poll.h")]
797 public const int POLLRDHUP;
798 [CCode (cheader_filename = "poll.h")]
799 public const int POLLERR;
800 [CCode (cheader_filename = "poll.h")]
801 public const int POLLHUP;
802 [CCode (cheader_filename = "poll.h")]
803 public const int POLLNVAL;
806 [IntegerType (rank = 9)]
807 [CCode (cheader_filename = "poll.h", cname = "nfds_t")]
808 public struct nfds_t {
811 [CCode (cheader_filename = "poll.h")]
812 public int poll (pollfd fds, nfds_t nfds, int timeout);
813 [CCode (cheader_filename = "poll.h")]
814 public int ppoll (pollfd fds, nfds_t nfds, timespec? timeout, sigset_t? sigmask);
817 [CCode (cname = "struct passwd", cheader_filename = "pwd.h")]
818 public class Passwd {
819 public string pw_name;
820 public string pw_passwd;
823 public string pw_gecos;
824 public string pw_dir;
825 public string pw_shell;
827 [CCode (cheader_filename = "pwd.h")]
828 public void endpwent ();
829 public unowned Passwd? getpwent ();
830 public void setpwent ();
831 [CCode (cheader_filename = "pwd.h")]
832 public unowned Passwd? getpwnam (string name);
834 [CCode (cheader_filename = "sys/resource.h")]
835 public const int PRIO_PROCESS;
836 [CCode (cheader_filename = "sys/resource.h")]
837 public const int PRIO_PGRP;
838 [CCode (cheader_filename = "sys/resource.h")]
839 public const int PRIO_USER;
841 [CCode (cheader_filename = "signal.h")]
842 public const int SIGABRT;
843 [CCode (cheader_filename = "signal.h")]
844 public const int SIGALRM;
845 [CCode (cheader_filename = "signal.h")]
846 public const int SIGBUS;
847 [CCode (cheader_filename = "signal.h")]
848 public const int SIGCHLD;
849 [CCode (cheader_filename = "signal.h")]
850 public const int SIGCONT;
851 [CCode (cheader_filename = "signal.h")]
852 public const int SIGFPE;
853 [CCode (cheader_filename = "signal.h")]
854 public const int SIGHUP;
855 [CCode (cheader_filename = "signal.h")]
856 public const int SIGILL;
857 [CCode (cheader_filename = "signal.h")]
858 public const int SIGINT;
859 [CCode (cheader_filename = "signal.h")]
860 public const int SIGKILL;
861 [CCode (cheader_filename = "signal.h")]
862 public const int SIGPIPE;
863 [CCode (cheader_filename = "signal.h")]
864 public const int SIGQUIT;
865 [CCode (cheader_filename = "signal.h")]
866 public const int SIGSEGV;
867 [CCode (cheader_filename = "signal.h")]
868 public const int SIGSTOP;
869 [CCode (cheader_filename = "signal.h")]
870 public const int SIGTERM;
871 [CCode (cheader_filename = "signal.h")]
872 public const int SIGTSTP;
873 [CCode (cheader_filename = "signal.h")]
874 public const int SIGTTIN;
875 [CCode (cheader_filename = "signal.h")]
876 public const int SIGTTOU;
877 [CCode (cheader_filename = "signal.h")]
878 public const int SIGUSR1;
879 [CCode (cheader_filename = "signal.h")]
880 public const int SIGUSR2;
881 [CCode (cheader_filename = "signal.h")]
882 public const int SIGPOLL;
883 [CCode (cheader_filename = "signal.h")]
884 public const int SIGPROF;
885 [CCode (cheader_filename = "signal.h")]
886 public const int SIGSYS;
887 [CCode (cheader_filename = "signal.h")]
888 public const int SIGTRAP;
889 [CCode (cheader_filename = "signal.h")]
890 public const int SIGURG;
891 [CCode (cheader_filename = "signal.h")]
892 public const int SIGVTALRM;
893 [CCode (cheader_filename = "signal.h")]
894 public const int SIGXCPU;
895 [CCode (cheader_filename = "signal.h")]
896 public const int SIGXFSZ;
897 [CCode (cheader_filename = "signal.h")]
898 public const int SIGIOT;
899 [CCode (cheader_filename = "signal.h")]
900 public const int SIGSTKFLT;
903 [IntegerType (rank = 6)]
904 [CCode (cname = "pid_t", default_value = "0", cheader_filename = "sys/types.h")]
905 public struct pid_t {
908 [CCode (cname = "struct sigaction", cheader_filename = "signal.h")]
909 public struct sigaction_t {
910 sighandler_t sa_handler;
915 [CCode (cheader_filename = "signal.h")]
916 public int kill (pid_t pid, int signum);
917 [CCode (cheader_filename = "signal.h")]
918 public int killpg (pid_t pgpr, int signum);
919 [CCode (cheader_filename = "signal.h")]
920 public int raise (int signum);
921 [CCode (cheader_filename = "signal.h")]
922 public int sigemptyset (sigset_t sigset);
923 [CCode (cheader_filename = "signal.h")]
924 public int sigfillset (sigset_t sigset);
925 [CCode (cheader_filename = "signal.h")]
926 public int sigaddset (sigset_t sigset, int signo);
927 [CCode (cheader_filename = "signal.h")]
928 public int sigdelset (sigset_t sigset, int __signo);
929 [CCode (cheader_filename = "signal.h")]
930 public int sigismember (sigset_t sigset, int __signo);
931 [CCode (cheader_filename = "signal.h")]
932 public int sigprocmask (int how, sigset_t sigset, sigset_t oset);
933 [CCode (cheader_filename = "signal.h")]
934 public int sigsuspend (sigset_t sigset);
935 [CCode (cheader_filename = "signal.h")]
936 public int sigpending (sigset_t sigset);
937 [CCode (cheader_filename = "signal.h")]
938 public int sigwait (sigset_t sigset, out int sig);
939 [CCode (cheader_filename = "signal.h")]
940 public int sigaction (int signum, sigaction_t? act, out sigaction_t? oldact);
942 [CCode (has_target = false, cheader_filename = "signal.h")]
943 public delegate void sighandler_t (int signal);
945 [CCode (cheader_filename = "signal.h")]
946 public sighandler_t SIG_DFL;
948 [CCode (cheader_filename = "signal.h")]
949 public sighandler_t SIG_ERR;
951 [CCode (cheader_filename = "signal.h")]
952 public sighandler_t SIG_IGN;
954 [CCode (cheader_filename = "signal.h")]
955 public sighandler_t signal (int signum, sighandler_t? handler);
957 [CCode (cheader_filename = "stdio.h")]
959 public void printf (string format,...);
961 [CCode (cheader_filename = "stdlib.h")]
962 public void abort ();
963 [CCode (cheader_filename = "stdlib.h")]
964 public void exit (int status);
966 [CCode (cheader_filename = "stdlib.h")]
967 public void _exit (int status);
969 public delegate void AtExitFunc ();
971 [CCode (cheader_filename = "stdlib.h")]
972 public void atexit (AtExitFunc func);
974 [CCode (cheader_filename = "stdlib.h")]
975 public int mkstemp (string template);
977 [CCode (cheader_filename = "stdlib.h")]
978 public int mkostemp (string template, int flags);
980 [CCode (cheader_filename = "stdlib.h")]
981 public int posix_openpt (int flags);
982 [CCode (cheader_filename = "stdlib.h")]
983 public int grantpt (int fd);
984 [CCode (cheader_filename = "stdlib.h")]
985 public int unlockpt (int fd);
987 [CCode (cheader_filename = "stdlib.h")]
988 public int system (string command);
990 [CCode (has_target = false, cheader_filename = "stdlib.h", cname = "__compar_fn_t")]
991 public delegate int compar_fn_t (void* key1, void* key2);
993 [CCode (cheader_filename = "stdlib.h")]
994 public void* bsearch (void* key, void* base, size_t nmemb, size_t size, compar_fn_t func);
996 [CCode (cheader_filename = "stdlib.h")]
997 public void qsort (void* base, size_t nmemb, size_t size, compar_fn_t func);
999 [CCode (cheader_filename = "stdlib.h")]
1000 public void qsort_r (void* base, size_t nmemb, size_t size, compar_fn_t func, void* arg);
1002 [CCode (cheader_filename = "stdlib.h")]
1003 public const int EXIT_FAILURE;
1004 [CCode (cheader_filename = "stdlib.h")]
1005 public const int EXIT_SUCCESS;
1007 [CCode (cheader_filename = "string.h")]
1008 public void* memccpy (void* s1, void* s2, int c, size_t n);
1009 [CCode (cheader_filename = "string.h")]
1010 public void* memchr (void* s, int c, size_t n);
1011 [CCode (cheader_filename = "string.h")]
1012 public int memcmp (void* s1, void* s2, size_t n);
1013 [CCode (cheader_filename = "string.h")]
1014 public void* memcpy (void* s1, void* s2, size_t n);
1015 [CCode (cheader_filename = "string.h")]
1016 public void* memmove (void* s1, void* s2, size_t n);
1017 [CCode (cheader_filename = "string.h")]
1018 public void* memset (void* s, int c, size_t n);
1019 [CCode (cheader_filename = "string.h")]
1020 public unowned string strcat (string s1, string s2);
1021 [CCode (cheader_filename = "string.h")]
1022 public unowned string strchr (string s, int c);
1023 [CCode (cheader_filename = "string.h")]
1024 public int strcmp (string s1, string s2);
1025 [CCode (cheader_filename = "string.h")]
1026 public int strcoll (string s1, string s2);
1027 [CCode (cheader_filename = "string.h")]
1028 public unowned string strcpy (string s1, string s2);
1029 [CCode (cheader_filename = "string.h")]
1030 public size_t strcspn (string s1, string s2);
1031 [CCode (cheader_filename = "string.h")]
1032 public unowned string strdup (string s1);
1033 [CCode (cheader_filename = "string.h")]
1034 public unowned string strerror (int errnum);
1035 [CCode (cheader_filename = "string.h")]
1036 public int* strerror_r (int errnum, string strerrbuf, size_t buflen);
1037 [CCode (cheader_filename = "string.h")]
1038 public size_t strlen (string s);
1039 [CCode (cheader_filename = "string.h")]
1040 public unowned string strncat (string s1, string s2, size_t n);
1041 [CCode (cheader_filename = "string.h")]
1042 public int strncmp (string s1, string s2, size_t n);
1043 [CCode (cheader_filename = "string.h")]
1044 public unowned string strncpy (string s1, string s2, size_t n);
1045 [CCode (cheader_filename = "string.h")]
1046 public unowned string strpbrk (string s1, string s2);
1047 [CCode (cheader_filename = "string.h")]
1048 public unowned string strrchr (string s, int c);
1049 [CCode (cheader_filename = "string.h")]
1050 public size_t strspn (string s1, string s2);
1051 [CCode (cheader_filename = "string.h")]
1052 public unowned string strstr (string s1, string s2);
1053 [CCode (cheader_filename = "string.h")]
1054 public unowned string strtok (string s1, string s2);
1055 [CCode (cheader_filename = "string.h")]
1056 public unowned string strtok_r (string s, string sep, out string lasts);
1057 [CCode (cheader_filename = "string.h")]
1058 public size_t strxfrm (string s1, string s2, size_t n);
1060 [CCode (cheader_filename = "stropts.h")]
1061 public const int I_PUSH;
1062 [CCode (cheader_filename = "stropts.h")]
1063 public const int I_POP;
1064 [CCode (cheader_filename = "stropts.h")]
1065 public const int I_LOOK;
1066 [CCode (cheader_filename = "stropts.h")]
1067 public const int I_FLUSH;
1068 [CCode (cheader_filename = "stropts.h")]
1069 public const int I_FLUSHBAND;
1070 [CCode (cheader_filename = "stropts.h")]
1071 public const int I_SETSIG;
1072 [CCode (cheader_filename = "stropts.h")]
1073 public const int I_GETSIG;
1074 [CCode (cheader_filename = "stropts.h")]
1075 public const int I_FIND;
1076 [CCode (cheader_filename = "stropts.h")]
1077 public const int I_PEEK;
1078 [CCode (cheader_filename = "stropts.h")]
1079 public const int I_SRDOPT;
1080 [CCode (cheader_filename = "stropts.h")]
1081 public const int I_GRDOPT;
1082 [CCode (cheader_filename = "stropts.h")]
1083 public const int I_NREAD;
1084 [CCode (cheader_filename = "stropts.h")]
1085 public const int I_FDINSERT;
1086 [CCode (cheader_filename = "stropts.h")]
1087 public const int I_STR;
1088 [CCode (cheader_filename = "stropts.h")]
1089 public const int I_SWROPT;
1090 [CCode (cheader_filename = "stropts.h")]
1091 public const int I_GWROPT;
1092 [CCode (cheader_filename = "stropts.h")]
1093 public const int I_SENDFD;
1094 [CCode (cheader_filename = "stropts.h")]
1095 public const int I_RECVFD;
1096 [CCode (cheader_filename = "stropts.h")]
1097 public const int I_LIST;
1098 [CCode (cheader_filename = "stropts.h")]
1099 public const int I_ATMARK;
1100 [CCode (cheader_filename = "stropts.h")]
1101 public const int I_CKBAND;
1102 [CCode (cheader_filename = "stropts.h")]
1103 public const int I_GETBAND;
1104 [CCode (cheader_filename = "stropts.h")]
1105 public const int I_CANPUT;
1106 [CCode (cheader_filename = "stropts.h")]
1107 public const int I_SETCLTIME;
1108 [CCode (cheader_filename = "stropts.h")]
1109 public const int I_GETCLTIME;
1110 [CCode (cheader_filename = "stropts.h")]
1111 public const int I_LINK;
1112 [CCode (cheader_filename = "stropts.h")]
1113 public const int I_UNLINK;
1114 [CCode (cheader_filename = "stropts.h")]
1115 public const int I_PLINK;
1116 [CCode (cheader_filename = "stropts.h")]
1117 public const int I_PUNLINK;
1118 [CCode (cheader_filename = "stropts.h")]
1119 public const int FLUSHR;
1120 [CCode (cheader_filename = "stropts.h")]
1121 public const int FLUSHW;
1122 [CCode (cheader_filename = "stropts.h")]
1123 public const int FLUSHRW;
1124 [CCode (cheader_filename = "stropts.h")]
1125 public const int S_RDNORM;
1126 [CCode (cheader_filename = "stropts.h")]
1127 public const int S_RDBAND;
1128 [CCode (cheader_filename = "stropts.h")]
1129 public const int S_INPUT;
1130 [CCode (cheader_filename = "stropts.h")]
1131 public const int S_HIPRI;
1132 [CCode (cheader_filename = "stropts.h")]
1133 public const int S_OUTPUT;
1134 [CCode (cheader_filename = "stropts.h")]
1135 public const int S_WRNORM;
1136 [CCode (cheader_filename = "stropts.h")]
1137 public const int S_WRBAND;
1138 [CCode (cheader_filename = "stropts.h")]
1139 public const int S_MSG;
1140 [CCode (cheader_filename = "stropts.h")]
1141 public const int S_ERROR;
1142 [CCode (cheader_filename = "stropts.h")]
1143 public const int S_HANGUP;
1144 [CCode (cheader_filename = "stropts.h")]
1145 public const int S_BANDURG;
1146 [CCode (cheader_filename = "stropts.h")]
1147 public const int RS_HIPRI;
1148 [CCode (cheader_filename = "stropts.h")]
1149 public const int RNORM;
1150 [CCode (cheader_filename = "stropts.h")]
1151 public const int RMSGD;
1152 [CCode (cheader_filename = "stropts.h")]
1153 public const int RMSGN;
1154 [CCode (cheader_filename = "stropts.h")]
1155 public const int RPROTNORN;
1156 [CCode (cheader_filename = "stropts.h")]
1157 public const int RPROTDAT;
1158 [CCode (cheader_filename = "stropts.h")]
1159 public const int RPROTDIS;
1160 [CCode (cheader_filename = "stropts.h")]
1161 public const int SNDZERO;
1162 [CCode (cheader_filename = "stropts.h")]
1163 public const int ANYMARK;
1164 [CCode (cheader_filename = "stropts.h")]
1165 public const int LASTMARK;
1166 [CCode (cheader_filename = "stropts.h")]
1167 public const int MUXID_ALL;
1168 [CCode (cheader_filename = "stropts.h")]
1169 public const int MSG_ANY;
1170 [CCode (cheader_filename = "stropts.h")]
1171 public const int MSG_BAND;
1172 [CCode (cheader_filename = "stropts.h")]
1173 public const int MSG_HIPRI;
1174 [CCode (cheader_filename = "stropts.h")]
1175 public const int MORECTL;
1176 [CCode (cheader_filename = "stropts.h")]
1177 public const int MOREDATA;
1178 [CCode (cheader_filename = "stropts.h", sentinel = "")]
1179 public int ioctl (int fildes, int request, ...);
1181 [CCode (cheader_filename = "syslog.h")]
1182 public void openlog (string ident, int option, int facility );
1184 [CCode (cheader_filename = "syslog.h")]
1185 public void syslog (int priority, string format, ... );
1187 [CCode (cheader_filename = "syslog.h")]
1188 public void closelog ();
1190 [CCode (cheader_filename = "syslog.h")]
1191 public const int LOG_PID;
1192 [CCode (cheader_filename = "syslog.h")]
1193 public const int LOG_CONS;
1194 [CCode (cheader_filename = "syslog.h")]
1195 public const int LOG_ODELAY;
1196 [CCode (cheader_filename = "syslog.h")]
1197 public const int LOG_NDELAY;
1198 [CCode (cheader_filename = "syslog.h")]
1199 public const int LOG_NOWAIT;
1200 [CCode (cheader_filename = "syslog.h")]
1201 public const int LOG_EMERG;
1202 [CCode (cheader_filename = "syslog.h")]
1203 public const int LOG_ALERT;
1204 [CCode (cheader_filename = "syslog.h")]
1205 public const int LOG_CRIT;
1206 [CCode (cheader_filename = "syslog.h")]
1207 public const int LOG_ERR;
1208 [CCode (cheader_filename = "syslog.h")]
1209 public const int LOG_WARNING;
1210 [CCode (cheader_filename = "syslog.h")]
1211 public const int LOG_NOTICE;
1212 [CCode (cheader_filename = "syslog.h")]
1213 public const int LOG_INFO;
1214 [CCode (cheader_filename = "syslog.h")]
1215 public const int LOG_DEBUG;
1216 [CCode (cheader_filename = "syslog.h")]
1217 public const int LOG_KERN;
1218 [CCode (cheader_filename = "syslog.h")]
1219 public const int LOG_USER;
1220 [CCode (cheader_filename = "syslog.h")]
1221 public const int LOG_MAIL;
1222 [CCode (cheader_filename = "syslog.h")]
1223 public const int LOG_DAEMON;
1224 [CCode (cheader_filename = "syslog.h")]
1225 public const int LOG_SYSLOG;
1226 [CCode (cheader_filename = "syslog.h")]
1227 public const int LOG_LPR;
1228 [CCode (cheader_filename = "syslog.h")]
1229 public const int LOG_NEWS;
1230 [CCode (cheader_filename = "syslog.h")]
1231 public const int LOG_UUCP;
1232 [CCode (cheader_filename = "syslog.h")]
1233 public const int LOG_CRON;
1234 [CCode (cheader_filename = "syslog.h")]
1235 public const int LOG_AUTHPRIV;
1236 [CCode (cheader_filename = "syslog.h")]
1237 public const int LOG_FTP;
1238 [CCode (cheader_filename = "syslog.h")]
1239 public const int LOG_LOCAL0;
1240 [CCode (cheader_filename = "syslog.h")]
1241 public const int LOG_LOCAL1;
1242 [CCode (cheader_filename = "syslog.h")]
1243 public const int LOG_LOCAL2;
1244 [CCode (cheader_filename = "syslog.h")]
1245 public const int LOG_LOCAL3;
1246 [CCode (cheader_filename = "syslog.h")]
1247 public const int LOG_LOCAL4;
1248 [CCode (cheader_filename = "syslog.h")]
1249 public const int LOG_LOCAL5;
1250 [CCode (cheader_filename = "syslog.h")]
1251 public const int LOG_LOCAL6;
1252 [CCode (cheader_filename = "syslog.h")]
1253 public const int LOG_LOCAL7;
1255 [CCode (cheader_filename = "sys/socket.h")]
1256 public const int SOCK_DGRAM;
1257 [CCode (cheader_filename = "sys/socket.h")]
1258 public const int SOCK_RAW;
1259 [CCode (cheader_filename = "sys/socket.h")]
1260 public const int SOCK_SEQPACKET;
1261 [CCode (cheader_filename = "sys/socket.h")]
1262 public const int SOCK_STREAM;
1263 [CCode (cheader_filename = "sys/socket.h")]
1264 public const int AF_INET;
1265 [CCode (cheader_filename = "sys/socket.h")]
1266 public const int AF_INET6;
1267 [CCode (cheader_filename = "sys/socket.h")]
1268 public const int AF_UNIX;
1269 [CCode (cheader_filename = "sys/socket.h", sentinel = "")]
1270 public int accept (int sfd, ... );
1271 [CCode (cheader_filename = "sys/socket.h", sentinel = "")]
1272 public int bind (int sockfd, ...);
1273 [CCode (cheader_filename = "sys/socket.h", sentinel = "")]
1274 public int connect(int sfd, ... );
1275 [CCode (cheader_filename = "sys/socket.h")]
1276 public int listen (int sfd, int backlog);
1277 [CCode (cheader_filename = "sys/socket.h")]
1278 public int socket (int domain, int type, int protocol);
1280 [CCode (cheader_filename = "sys/socket.h")]
1281 public int socketpair (int domain, int type, int protocol, int[] sv);
1284 [CCode (cname = "struct in_addr", cheader_filename = "sys/socket.h", destroy_function = "")]
1285 public struct InAddr {
1286 public uint32 s_addr;
1289 [CCode (cname = "struct sockaddr", cheader_filename = "sys/socket.h", destroy_function = "")]
1290 public struct SockAddr {
1293 [CCode (cname = "struct sockaddr_in", cheader_filename = "netinet/in.h", destroy_function = "")]
1294 public struct SockAddrIn {
1295 public int sin_family;
1296 public uint16 sin_port;
1297 public InAddr sin_addr;
1300 [CCode (cheader_filename = "sys/stat.h")]
1301 public int mkfifo (string filename, mode_t mode);
1303 [CCode (cheader_filename = "sys/stat.h")]
1304 public const mode_t S_IFMT;
1305 [CCode (cheader_filename = "sys/stat.h")]
1306 public const mode_t S_IFBLK;
1307 [CCode (cheader_filename = "sys/stat.h")]
1308 public const mode_t S_IFCHR;
1309 [CCode (cheader_filename = "sys/stat.h")]
1310 public const mode_t S_IFIFO;
1311 [CCode (cheader_filename = "sys/stat.h")]
1312 public const mode_t S_IFREG;
1313 [CCode (cheader_filename = "sys/stat.h")]
1314 public const mode_t S_IFDIR;
1315 [CCode (cheader_filename = "sys/stat.h")]
1316 public const mode_t S_IFLNK;
1317 [CCode (cheader_filename = "sys/stat.h")]
1318 public const mode_t S_IFSOCK;
1320 [CCode (cheader_filename = "sys/stat.h")]
1321 public const mode_t S_IRWXU;
1322 [CCode (cheader_filename = "sys/stat.h")]
1323 public const mode_t S_IRUSR;
1324 [CCode (cheader_filename = "sys/stat.h")]
1325 public const mode_t S_IWUSR;
1326 [CCode (cheader_filename = "sys/stat.h")]
1327 public const mode_t S_IXUSR;
1328 [CCode (cheader_filename = "sys/stat.h")]
1329 public const mode_t S_IRWXG;
1330 [CCode (cheader_filename = "sys/stat.h")]
1331 public const mode_t S_IRGRP;
1332 [CCode (cheader_filename = "sys/stat.h")]
1333 public const mode_t S_IWGRP;
1334 [CCode (cheader_filename = "sys/stat.h")]
1335 public const mode_t S_IXGRP;
1336 [CCode (cheader_filename = "sys/stat.h")]
1337 public const mode_t S_IRWXO;
1338 [CCode (cheader_filename = "sys/stat.h")]
1339 public const mode_t S_IROTH;
1340 [CCode (cheader_filename = "sys/stat.h")]
1341 public const mode_t S_IWOTH;
1342 [CCode (cheader_filename = "sys/stat.h")]
1343 public const mode_t S_IXOTH;
1344 [CCode (cheader_filename = "sys/stat.h")]
1345 public const mode_t S_ISUID;
1346 [CCode (cheader_filename = "sys/stat.h")]
1347 public const mode_t S_ISGID;
1348 [CCode (cheader_filename = "sys/stat.h")]
1349 public const mode_t S_ISVTX;
1351 [CCode (cheader_filename = "sys/stat.h")]
1352 public bool S_ISBLK (mode_t mode);
1353 [CCode (cheader_filename = "sys/stat.h")]
1354 public bool S_ISCHR (mode_t mode);
1355 [CCode (cheader_filename = "sys/stat.h")]
1356 public bool S_ISDIR (mode_t mode);
1357 [CCode (cheader_filename = "sys/stat.h")]
1358 public bool S_ISFIFO (mode_t mode);
1359 [CCode (cheader_filename = "sys/stat.h")]
1360 public bool S_ISREG (mode_t mode);
1361 [CCode (cheader_filename = "sys/stat.h")]
1362 public bool S_ISLNK (mode_t mode);
1363 [CCode (cheader_filename = "sys/stat.h")]
1364 public bool S_ISSOCK (mode_t mode);
1366 [CCode (cheader_filename = "sys/stat.h", cname = "struct stat")]
1367 public struct Stat {
1368 public dev_t st_dev;
1369 public ino_t st_ino;
1370 public mode_t st_mode;
1371 public nlink_t st_nlink;
1372 public uid_t st_uid;
1373 public gid_t st_gid;
1374 public dev_t st_rdev;
1375 public size_t st_size;
1376 public time_t st_atime;
1377 public time_t st_mtime;
1378 public time_t st_ctime;
1379 public blksize_t st_blksize;
1380 public blkcnt_t st_blocks;
1382 [CCode (cheader_filename = "sys/stat.h")]
1383 int fstat( int fd, out Stat buf);
1384 [CCode (cheader_filename = "sys/stat.h")]
1385 int stat (string filename, out Stat buf);
1386 [CCode (cheader_filename = "sys/stat.h")]
1387 int lstat (string filename, out Stat buf);
1389 [CCode (cheader_filename = "sys/stat.h")]
1390 public int chmod (string filename, mode_t mode);
1391 [CCode (cheader_filename = "sys/stat.h")]
1392 public mode_t umask (mode_t mask);
1393 [CCode (cheader_filename = "sys/stat.h")]
1394 public int mkdir (string path, mode_t mode);
1395 [CCode (cheader_filename = "sys/types.h,sys/stat.h,fcntl.h,unistd.h")]
1396 public pid_t mknod (string pathname, mode_t mode, dev_t dev);
1398 [CCode (cheader_filename = "sys/wait.h")]
1399 public pid_t wait (out int status);
1400 [CCode (cheader_filename = "sys/wait.h")]
1401 public pid_t waitpid (pid_t pid, out int status, int options);
1402 [CCode (cheader_filename = "sys/wait.h")]
1403 public const int WNOHANG;
1404 [CCode (cheader_filename = "sys/wait.h")]
1405 public const int WUNTRACED;
1406 [CCode (cheader_filename = "sys/wait.h")]
1407 public const int WCONTINUED;
1410 [IntegerType (rank = 9)]
1411 [CCode (cheader_filename = "sys/types.h", cname = "key_t")]
1412 public struct key_t {
1416 [IntegerType (rank = 9)]
1417 [CCode (cheader_filename = "sys/statvfs.h")]
1418 public struct fsblkcnt_t {
1422 [IntegerType (rank = 9)]
1423 [CCode (cheader_filename = "sys/statvfs.h")]
1424 public struct fsfilcnt_t {
1427 [CCode (cheader_filename = "sys/statvfs.h", cname = "struct statvfs")]
1428 public struct statvfs {
1429 public ulong f_bsize;
1430 public ulong f_frsize;
1431 public fsblkcnt_t f_blocks;
1432 public fsblkcnt_t f_bfree;
1433 public fsblkcnt_t f_bavail;
1434 public fsfilcnt_t f_files;
1435 public fsfilcnt_t f_ffree;
1436 public fsfilcnt_t f_favail;
1440 [IntegerType (rank = 9)]
1441 [CCode (cname="off_t", cheader_filename = "sys/types.h")]
1442 public struct off_t {
1446 [IntegerType (rank = 9)]
1447 [CCode (cheader_filename = "sys/types.h")]
1448 public struct uid_t {
1452 [IntegerType (rank = 9)]
1453 [CCode (cheader_filename = "sys/types.h")]
1454 public struct gid_t {
1458 [IntegerType (rank = 9)]
1459 [CCode (cname = "mode_t", cheader_filename = "sys/types.h")]
1460 public struct mode_t {
1464 [IntegerType (rank = 9)]
1465 [CCode (cheader_filename = "sys/types.h")]
1466 public struct dev_t {
1470 [IntegerType (rank = 9)]
1471 [CCode (cheader_filename = "sys/types.h")]
1472 public struct ino_t {
1476 [IntegerType (rank = 9)]
1477 [CCode (cheader_filename = "sys/types.h")]
1478 public struct nlink_t {
1482 [IntegerType (rank = 9)]
1483 [CCode (cheader_filename = "sys/types.h")]
1484 public struct blksize_t {
1488 [IntegerType (rank = 9)]
1489 [CCode (cheader_filename = "sys/types.h")]
1490 public struct blkcnt_t {
1493 [CCode (cheader_filename = "time.h")]
1503 public int tm_isdst;
1506 [CCode (cname = "struct timespec", cheader_filename = "time.h")]
1507 public struct timespec {
1508 public time_t tv_sec;
1509 public long tv_nsec;
1512 [CCode (cheader_filename = "sys/time.h,sys/resource.h")]
1513 public int getpriority (int which, int who);
1514 [CCode (cheader_filename = "sys/time.h,sys/resource.h")]
1515 public int setpriority (int which, int who, int prio);
1517 [CCode (cheader_filename = "unistd.h")]
1518 public int close (int fd);
1519 [CCode (cheader_filename = "unistd.h")]
1520 public int execl (string path, params string[] arg);
1521 [CCode (cheader_filename = "unistd.h")]
1522 public int execlp (string path, params string[] arg);
1523 [CCode (cheader_filename = "unistd.h")]
1524 public int pipe ([CCode (array_length = false, null_terminated = false)] int[] pipefd);
1525 [CCode (cheader_filename = "unistd.h")]
1526 public ssize_t read (int fd, void* buf, size_t count);
1527 [CCode (cheader_filename = "unistd.h")]
1528 public ssize_t readlink (string path, char[] buf);
1529 [CCode (cheader_filename = "unistd.h,sys/types.h")]
1530 public int setgid (gid_t gid);
1531 [CCode (cheader_filename = "unistd.h,sys/types.h")]
1532 public int setuid (uid_t uid);
1533 [CCode (cheader_filename = "unistd.h")]
1534 public int unlink (string filename);
1535 [CCode (cheader_filename = "unistd.h")]
1536 public ssize_t write (int fd, void* buf, size_t count);
1537 [CCode (cheader_filename = "unistd.h")]
1538 public off_t lseek(int fildes, off_t offset, int whence);
1540 [CCode (cheader_filename = "unistd.h")]
1541 public const int SEEK_SET;
1542 [CCode (cheader_filename = "unistd.h")]
1543 public const int SEEK_CUR;
1544 [CCode (cheader_filename = "unistd.h")]
1545 public const int SEEK_END;
1547 [CCode (cheader_filename = "unistd.h")]
1548 public pid_t fork ();
1549 [CCode (cheader_filename = "unistd.h")]
1550 public pid_t vfork ();
1551 [CCode (cheader_filename = "unistd.h")]
1552 public unowned string ttyname (int fd);
1553 [CCode (cheader_filename = "unistd.h")]
1554 public int ttyname_r (int fd, char[] buf);
1555 [CCode (cheader_filename = "unistd.h")]
1556 public bool isatty (int fd);
1557 [CCode (cheader_filename = "unistd.h")]
1558 public int link (string from, string to);
1559 [CCode (cheader_filename = "unistd.h")]
1560 public int symlink (string from, string to);
1561 [CCode (cheader_filename = "unistd.h")]
1562 public long sysconf (int name);
1563 [CCode (cheader_filename = "unistd.h")]
1564 public int rmdir (string path);
1565 [CCode (cheader_filename = "unistd.h")]
1566 public pid_t tcgetpgrp (int fd);
1567 [CCode (cheader_filename = "unistd.h")]
1568 public int tcsetpgrp (int fd, pid_t pgrp_id);
1569 [CCode (cheader_filename = "unistd.h")]
1570 public unowned string getlogin ();
1571 [CCode (cheader_filename = "unistd.h")]
1572 public int vhangup ();
1573 [CCode (cheader_filename = "unistd.h")]
1574 public int revoke (string file);
1575 [CCode (cheader_filename = "unistd.h")]
1576 public int acct (string name);
1577 [CCode (cheader_filename = "unistd.h")]
1578 public unowned string getusershell ();
1579 [CCode (cheader_filename = "unistd.h")]
1580 public void endusershell ();
1581 [CCode (cheader_filename = "unistd.h")]
1582 public void setusershell ();
1583 [CCode (cheader_filename = "unistd.h")]
1584 public int chroot (string path);
1585 [CCode (cheader_filename = "unistd.h")]
1586 public unowned string getpass (string promt);
1587 [CCode (cheader_filename = "unistd.h")]
1588 public int getpagesize ();
1589 [CCode (cheader_filename = "unistd.h")]
1590 public int getdtablesize ();
1592 [CCode (cheader_filename = "unistd.h")]
1593 public const int _SC_ARG_MAX;
1594 [CCode (cheader_filename = "unistd.h")]
1595 public const int _SC_CHILD_MAX;
1596 [CCode (cheader_filename = "unistd.h")]
1597 public const int _SC_HOST_NAME_MAX;
1598 [CCode (cheader_filename = "unistd.h")]
1599 public const int _SC_LOGIN_NAME_MAX;
1600 [CCode (cheader_filename = "unistd.h")]
1601 public const int _SC_CLK_TCK;
1602 [CCode (cheader_filename = "unistd.h")]
1603 public const int _SC_OPEN_MAX;
1604 [CCode (cheader_filename = "unistd.h")]
1605 public const int _SC_PAGESIZE;
1606 [CCode (cheader_filename = "unistd.h")]
1607 public const int _SC_RE_DUP_MAX;
1608 [CCode (cheader_filename = "unistd.h")]
1609 public const int _SC_STREAM_MAX;
1610 [CCode (cheader_filename = "unistd.h")]
1611 public const int _SC_SYMLOOP_MAX;
1612 [CCode (cheader_filename = "unistd.h")]
1613 public const int _SC_TTY_NAME_MAX;
1614 [CCode (cheader_filename = "unistd.h")]
1615 public const int _SC_TZNAME_MAX;
1616 [CCode (cheader_filename = "unistd.h")]
1617 public const int _SC_VERSION;
1618 [CCode (cheader_filename = "unistd.h")]
1619 public const int _SC_BASE_MAX;
1620 [CCode (cheader_filename = "unistd.h")]
1621 public const int _SC_BC_DIM_MAX;
1622 [CCode (cheader_filename = "unistd.h")]
1623 public const int _SC_BC_SCALE_MAX;
1624 [CCode (cheader_filename = "unistd.h")]
1625 public const int _SC_BC_STRING_MAX;
1626 [CCode (cheader_filename = "unistd.h")]
1627 public const int _SC_COLL_WEIGHTS_MAX;
1628 [CCode (cheader_filename = "unistd.h")]
1629 public const int _SC_EXRP_NEST_MAX;
1630 [CCode (cheader_filename = "unistd.h")]
1631 public const int _SC_LINE_MAX;
1632 [CCode (cheader_filename = "unistd.h")]
1633 public const int _SC_2_VERSION;
1634 [CCode (cheader_filename = "unistd.h")]
1635 public const int _SC_2_C_DEV;
1636 [CCode (cheader_filename = "unistd.h")]
1637 public const int _SC_2_FORT_DEV;
1638 [CCode (cheader_filename = "unistd.h")]
1639 public const int _SC_2_FORT_RUN;
1640 [CCode (cheader_filename = "unistd.h")]
1641 public const int _SC_2_LOCALEDEF;
1642 [CCode (cheader_filename = "unistd.h")]
1643 public const int _SC_2_SW_DEV;
1645 [CCode (cheader_filename = "unistd.h")]
1646 public const int STDIN_FILENO;
1647 [CCode (cheader_filename = "unistd.h")]
1648 public const int STDOUT_FILENO;
1649 [CCode (cheader_filename = "unistd.h")]
1650 public const int STDERR_FILENO;
1651 [CCode (cheader_filename = "unistd.h")]
1652 public const int R_OK;
1653 [CCode (cheader_filename = "unistd.h")]
1654 public const int W_OK;
1655 [CCode (cheader_filename = "unistd.h")]
1656 public const int X_OK;
1657 [CCode (cheader_filename = "unistd.h")]
1658 public const int F_OK;
1660 [CCode (cheader_filename = "unistd.h")]
1661 public int access (string patchname, int mode);
1662 [CCode (cheader_filename = "unistd.h")]
1663 public int euidaccess (string patchname, int mode);
1664 [CCode (cheader_filename = "unistd.h")]
1665 public int eaccess (string patchname, int mode);
1667 [CCode (cheader_filename = "unistd.h")]
1668 public uint alarm (uint seconds);
1669 [CCode (cheader_filename = "unistd.h")]
1670 public uint ualarm (uint useconds);
1671 [CCode (cheader_filename = "unistd.h")]
1672 public uint sleep (uint seconds);
1673 [CCode (cheader_filename = "unistd.h")]
1674 public uint usleep (uint useconds);
1675 [CCode (cheader_filename = "unistd.h")]
1676 public int pause ();
1677 [CCode (cheader_filename = "unistd.h")]
1678 public int chown (string filename, uid_t owner, gid_t group);
1679 [CCode (cheader_filename = "unistd.h")]
1680 public int fchown (int fd, uid_t owner, gid_t group);
1681 [CCode (cheader_filename = "unistd.h")]
1682 public int lchown (string filename, uid_t owner, gid_t group);
1683 [CCode (cheader_filename = "unistd.h")]
1684 public int chdir (string filepath);
1685 [CCode (cheader_filename = "unistd.h")]
1686 public int fchdir (int file);
1687 [CCode (cheader_filename = "unistd.h")]
1688 public int dup (int fd);
1689 [CCode (cheader_filename = "unistd.h")]
1690 public int dup2 (int fd1, int fd2);
1691 [CCode (cheader_filename = "unistd.h")]
1692 public int gethostname (char[] name);
1693 [CCode (cheader_filename = "unistd.h")]
1694 public pid_t getpid ();
1695 [CCode (cheader_filename = "unistd.h")]
1696 public pid_t getppid ();
1697 [CCode (cheader_filename = "unistd.h")]
1698 public pid_t getpgrp ();
1699 [CCode (cheader_filename = "unistd.h")]
1700 public pid_t getpgid (pid_t pid);
1701 [CCode (cheader_filename = "unistd.h")]
1702 public int setpgid (pid_t pid, pid_t pgid);
1703 [CCode (cheader_filename = "unistd.h")]
1704 public pid_t setpgrp ();
1705 [CCode (cheader_filename = "unistd.h")]
1706 public pid_t getsid (pid_t pid);
1707 [CCode (cheader_filename = "unistd.h")]
1708 public uid_t getuid ();
1709 [CCode (cheader_filename = "unistd.h")]
1710 public uid_t geteuid ();
1711 [CCode (cheader_filename = "unistd.h")]
1712 public gid_t getgid ();
1713 [CCode (cheader_filename = "unistd.h")]
1714 public gid_t getegid ();
1715 [CCode (cheader_filename = "unistd.h")]
1716 public int group_member (gid_t gid);
1717 [CCode (cheader_filename = "unistd.h")]
1718 public pid_t setsid ();
1719 [CCode (cheader_filename = "unistd.h")]
1720 public pid_t tcgetsid (int fd);
1722 [CCode (cheader_filename = "unistd.h")]
1723 public int fsync (int fd);
1724 [CCode (cheader_filename = "unistd.h")]
1725 public int fdatasync (int fd);
1726 [CCode (cheader_filename = "unistd.h")]
1729 [CCode (cheader_filename = "unistd.h")]
1730 public int ftruncate(int fd, off_t length);
1731 [CCode (cheader_filename = "unistd.h")]
1732 public int truncate(string path, off_t length);
1733 [CCode (cheader_filename = "unistd.h")]
1734 public int nice (int inc);
1737 [CCode (cname = "cc_t", cheader_filename = "termios.h")]
1738 [IntegerType (rank = 3, min = 0, max = 255)]
1739 public struct cc_t {
1743 [CCode (cname = "speed_t", cheader_filename = "termios.h")]
1744 [IntegerType (rank = 7)]
1745 public struct speed_t {
1749 [CCode (cname = "tcflag_t", cheader_filename = "termios.h")]
1750 [IntegerType (rank = 7)]
1751 public struct tcflag_t {
1754 [CCode (cname="struct termios", cheader_filename = "termios.h")]
1755 public struct termios
1757 public tcflag_t c_iflag;
1758 public tcflag_t c_oflag;
1759 public tcflag_t c_cflag;
1760 public tcflag_t c_lflag;
1762 public unowned cc_t[] c_cc;
1763 public speed_t c_ispeed;
1764 public speed_t c_ospeed;
1767 [CCode (cheader_filename = "termios.h")]
1768 public int tcgetattr (int fd, termios termios_p);
1769 [CCode (cheader_filename = "termios.h")]
1770 public int tcsetattr (int fd, int optional_actions, termios termios_p);
1771 [CCode (cheader_filename = "termios.h")]
1772 public int tcsendbreak (int fd, int duration);
1773 [CCode (cheader_filename = "termios.h")]
1774 public int tcdrain (int fd);
1775 [CCode (cheader_filename = "termios.h")]
1776 public int tcflush (int fd, int queue_selector);
1777 [CCode (cheader_filename = "termios.h")]
1778 public int tcflow (int fd, int action);
1779 [CCode (cheader_filename = "termios.h")]
1780 public void cfmakeraw (termios termios_p);
1781 [CCode (cheader_filename = "termios.h")]
1782 public speed_t cfgetispeed (termios termios_p);
1783 [CCode (cheader_filename = "termios.h")]
1784 public speed_t cfgetospeed (termios termios_p);
1785 [CCode (cheader_filename = "termios.h")]
1786 public int cfsetispeed (termios termios_p, speed_t speed);
1787 [CCode (cheader_filename = "termios.h")]
1788 public int cfsetospeed (termios termios_p, speed_t speed);
1789 [CCode (cheader_filename = "termios.h")]
1790 public int cfsetspeed (termios termios, speed_t speed);
1793 [CCode (cheader_filename = "termios.h")]
1794 public const tcflag_t IGNBRK;
1795 [CCode (cheader_filename = "termios.h")]
1796 public const tcflag_t BRKINT;
1797 [CCode (cheader_filename = "termios.h")]
1798 public const tcflag_t IGNPAR;
1799 [CCode (cheader_filename = "termios.h")]
1800 public const tcflag_t PARMRK;
1801 [CCode (cheader_filename = "termios.h")]
1802 public const tcflag_t INPCK;
1803 [CCode (cheader_filename = "termios.h")]
1804 public const tcflag_t ISTRIP;
1805 [CCode (cheader_filename = "termios.h")]
1806 public const tcflag_t INLCR;
1807 [CCode (cheader_filename = "termios.h")]
1808 public const tcflag_t IGNCR;
1809 [CCode (cheader_filename = "termios.h")]
1810 public const tcflag_t IXON;
1811 [CCode (cheader_filename = "termios.h")]
1812 public const tcflag_t IXANY;
1813 [CCode (cheader_filename = "termios.h")]
1814 public const tcflag_t IXOFF;
1815 [CCode (cheader_filename = "termios.h")]
1816 public const tcflag_t ICRNL;
1819 [CCode (cheader_filename = "termios.h")]
1820 public const tcflag_t OPOST;
1821 [CCode (cheader_filename = "termios.h")]
1822 public const tcflag_t ONLCR;
1823 [CCode (cheader_filename = "termios.h")]
1824 public const tcflag_t OCRNL;
1825 [CCode (cheader_filename = "termios.h")]
1826 public const tcflag_t ONOCR;
1827 [CCode (cheader_filename = "termios.h")]
1828 public const tcflag_t ONLRET;
1829 [CCode (cheader_filename = "termios.h")]
1830 public const tcflag_t OFILL;
1831 [CCode (cheader_filename = "termios.h")]
1832 public const tcflag_t NLDLY;
1833 [CCode (cheader_filename = "termios.h")]
1834 public const tcflag_t NL0;
1835 [CCode (cheader_filename = "termios.h")]
1836 public const tcflag_t NL1;
1837 [CCode (cheader_filename = "termios.h")]
1838 public const tcflag_t CRDLY;
1839 [CCode (cheader_filename = "termios.h")]
1840 public const tcflag_t CR0;
1841 [CCode (cheader_filename = "termios.h")]
1842 public const tcflag_t CR1;
1843 [CCode (cheader_filename = "termios.h")]
1844 public const tcflag_t CR2;
1845 [CCode (cheader_filename = "termios.h")]
1846 public const tcflag_t CR3;
1847 [CCode (cheader_filename = "termios.h")]
1848 public const tcflag_t TABDLY;
1849 [CCode (cheader_filename = "termios.h")]
1850 public const tcflag_t TAB0;
1851 [CCode (cheader_filename = "termios.h")]
1852 public const tcflag_t TAB1;
1853 [CCode (cheader_filename = "termios.h")]
1854 public const tcflag_t TAB2;
1855 [CCode (cheader_filename = "termios.h")]
1856 public const tcflag_t TAB3;
1857 [CCode (cheader_filename = "termios.h")]
1858 public const tcflag_t BSDLY;
1859 [CCode (cheader_filename = "termios.h")]
1860 public const tcflag_t BS0;
1861 [CCode (cheader_filename = "termios.h")]
1862 public const tcflag_t BS1;
1863 [CCode (cheader_filename = "termios.h")]
1864 public const tcflag_t VTDLY;
1865 [CCode (cheader_filename = "termios.h")]
1866 public const tcflag_t VT0;
1867 [CCode (cheader_filename = "termios.h")]
1868 public const tcflag_t VT1;
1869 [CCode (cheader_filename = "termios.h")]
1870 public const tcflag_t FFDLY;
1871 [CCode (cheader_filename = "termios.h")]
1872 public const tcflag_t FF0;
1873 [CCode (cheader_filename = "termios.h")]
1874 public const tcflag_t FF1;
1877 [CCode (cheader_filename = "termios.h")]
1878 public const tcflag_t CSIZE;
1879 [CCode (cheader_filename = "termios.h")]
1880 public const tcflag_t CS5;
1881 [CCode (cheader_filename = "termios.h")]
1882 public const tcflag_t CS6;
1883 [CCode (cheader_filename = "termios.h")]
1884 public const tcflag_t CS7;
1885 [CCode (cheader_filename = "termios.h")]
1886 public const tcflag_t CS8;
1887 [CCode (cheader_filename = "termios.h")]
1888 public const tcflag_t CSTOPB;
1889 [CCode (cheader_filename = "termios.h")]
1890 public const tcflag_t CREAD;
1891 [CCode (cheader_filename = "termios.h")]
1892 public const tcflag_t PARENB;
1893 [CCode (cheader_filename = "termios.h")]
1894 public const tcflag_t PARODD;
1895 [CCode (cheader_filename = "termios.h")]
1896 public const tcflag_t HUPCL;
1897 [CCode (cheader_filename = "termios.h")]
1898 public const tcflag_t CLOCAL;
1901 [CCode (cheader_filename = "termios.h")]
1902 public const tcflag_t ISIG;
1903 [CCode (cheader_filename = "termios.h")]
1904 public const tcflag_t ICANON;
1905 [CCode (cheader_filename = "termios.h")]
1906 public const tcflag_t ECHO;
1907 [CCode (cheader_filename = "termios.h")]
1908 public const tcflag_t ECHOE;
1909 [CCode (cheader_filename = "termios.h")]
1910 public const tcflag_t ECHOK;
1911 [CCode (cheader_filename = "termios.h")]
1912 public const tcflag_t ECHONL;
1913 [CCode (cheader_filename = "termios.h")]
1914 public const tcflag_t NOFLSH;
1915 [CCode (cheader_filename = "termios.h")]
1916 public const tcflag_t TOSTOP;
1917 [CCode (cheader_filename = "termios.h")]
1918 public const tcflag_t IEXTEN;
1921 [CCode (cheader_filename = "termios.h")]
1922 public const int VINTR;
1923 [CCode (cheader_filename = "termios.h")]
1924 public const int VQUIT;
1925 [CCode (cheader_filename = "termios.h")]
1926 public const int VERASE;
1927 [CCode (cheader_filename = "termios.h")]
1928 public const int VKILL;
1929 [CCode (cheader_filename = "termios.h")]
1930 public const int VEOF;
1931 [CCode (cheader_filename = "termios.h")]
1932 public const int VMIN;
1933 [CCode (cheader_filename = "termios.h")]
1934 public const int VEOL;
1935 [CCode (cheader_filename = "termios.h")]
1936 public const int VTIME;
1937 [CCode (cheader_filename = "termios.h")]
1938 public const int VSTART;
1939 [CCode (cheader_filename = "termios.h")]
1940 public const int VSTOP;
1941 [CCode (cheader_filename = "termios.h")]
1942 public const int VSUSP;
1945 [CCode (cheader_filename = "termios.h")]
1946 public const int TCSANOW;
1947 [CCode (cheader_filename = "termios.h")]
1948 public const int TCSADRAIN;
1949 [CCode (cheader_filename = "termios.h")]
1950 public const int TCSAFLUSH;
1953 [CCode (cheader_filename = "termios.h")]
1954 public const int TCIFLUSH;
1955 [CCode (cheader_filename = "termios.h")]
1956 public const int TCOFLUSH;
1957 [CCode (cheader_filename = "termios.h")]
1958 public const int TCIOFLUSH;
1961 [CCode (cheader_filename = "termios.h")]
1962 public const int TCOOFF;
1963 [CCode (cheader_filename = "termios.h")]
1964 public const int TCOON;
1965 [CCode (cheader_filename = "termios.h")]
1966 public const int TCIOFF;
1967 [CCode (cheader_filename = "termios.h")]
1968 public const int TCION;
1971 [CCode (cheader_filename = "termios.h")]
1972 public const speed_t B0;
1973 [CCode (cheader_filename = "termios.h")]
1974 public const speed_t B50;
1975 [CCode (cheader_filename = "termios.h")]
1976 public const speed_t B75;
1977 [CCode (cheader_filename = "termios.h")]
1978 public const speed_t B110;
1979 [CCode (cheader_filename = "termios.h")]
1980 public const speed_t B134;
1981 [CCode (cheader_filename = "termios.h")]
1982 public const speed_t B150;
1983 [CCode (cheader_filename = "termios.h")]
1984 public const speed_t B200;
1985 [CCode (cheader_filename = "termios.h")]
1986 public const speed_t B300;
1987 [CCode (cheader_filename = "termios.h")]
1988 public const speed_t B600;
1989 [CCode (cheader_filename = "termios.h")]
1990 public const speed_t B1200;
1991 [CCode (cheader_filename = "termios.h")]
1992 public const speed_t B1800;
1993 [CCode (cheader_filename = "termios.h")]
1994 public const speed_t B2400;
1995 [CCode (cheader_filename = "termios.h")]
1996 public const speed_t B4800;
1997 [CCode (cheader_filename = "termios.h")]
1998 public const speed_t B9600;
1999 [CCode (cheader_filename = "termios.h")]
2000 public const speed_t B19200;
2001 [CCode (cheader_filename = "termios.h")]
2002 public const speed_t B38400;
2003 [CCode (cheader_filename = "termios.h")]
2004 public const speed_t B57600;
2005 [CCode (cheader_filename = "termios.h")]
2006 public const speed_t B115200;
2007 [CCode (cheader_filename = "termios.h")]
2008 public const speed_t B230400;
2010 [CCode (cname = "fd_set", cheader_filename = "sys/select.h")]
2011 public struct fd_set {
2014 [CCode (cname = "struct timeval", cheader_filename = "sys/time.h")]
2015 public struct timeval {
2016 public time_t tv_sec;
2017 public long tv_usec;
2018 [CCode (cname = "gettimeofday")]
2019 public int get_time_of_day (void * timezone = null);
2020 [CCode (cname = "settimeofday")]
2021 public int set_time_of_day (void * timezone = null);
2024 [CCode (cname = "sigset_t", cheader_filename = "sys/select.h")]
2025 public struct sigset_t {
2028 [CCode (cheader_filename = "sys/select.h")]
2029 public int select (int nfds, fd_set? readfds, fd_set? writefds, fd_set? exceptfds, timeval timeout);
2030 [CCode (cheader_filename = "sys/select.h")]
2031 public void FD_CLR (int fd, fd_set @set);
2032 [CCode (cheader_filename = "sys/select.h")]
2033 public int FD_ISSET (int fd, fd_set @set);
2034 [CCode (cheader_filename = "sys/select.h")]
2035 public void FD_SET (int fd, fd_set @set);
2036 [CCode (cheader_filename = "sys/select.h")]
2037 public void FD_ZERO (fd_set @set);
2038 [CCode (cheader_filename = "sys/select.h")]
2039 public int pselect (int nfds, fd_set? readfds, fd_set? writefds, fd_set? exceptfds, timespec timeout, sigset_t sigmask);
2041 // sys/mman.h - Posix mmap(), munmap(), mprotect()
2042 [CCode (cheader_filename = "sys/mman.h")]
2043 public void *mmap(void *addr, size_t length, int prot, int flags, int fd, off_t offset);
2044 [CCode (cheader_filename = "sys/mman.h")]
2045 public int munmap(void *addr, size_t length);
2046 [CCode (cheader_filename = "sys/mman.h")]
2047 public int mprotect(void *addr, size_t len, int prot);
2048 [CCode (cheader_filename = "sys/mman.h")]
2049 public const int PROT_READ;
2050 [CCode (cheader_filename = "sys/mman.h")]
2051 public const int PROT_WRITE;
2052 [CCode (cheader_filename = "sys/mman.h")]
2053 public const int PROT_EXEC;
2054 [CCode (cheader_filename = "sys/mman.h")]
2055 public const int MAP_SHARED;
2056 [CCode (cheader_filename = "sys/mman.h")]
2057 public const int MAP_PRIVATE;
2058 [CCode (cheader_filename = "sys/mman.h")]
2059 public const int MAP_FIXED;
2060 [CCode (cheader_filename = "sys/mman.h")]
2061 public void *MAP_FAILED;
2062 // sys/mman.h - [MLR] Range Memory Locking
2063 [CCode (cheader_filename = "sys/mman.h")]
2064 public int mlock(void *addr, size_t len);
2065 [CCode (cheader_filename = "sys/mman.h")]
2066 public int munlock(void *addr, size_t len);
2067 // sys/mman.h - [XSI] X/Open System Interfaces
2068 [CCode (cheader_filename = "sys/mman.h")]
2069 public int msync(void *addr, size_t len, int flags);
2070 [CCode (cheader_filename = "sys/mman.h")]
2071 public const int MS_ASYNC;
2072 [CCode (cheader_filename = "sys/mman.h")]
2073 public const int MS_INVALIDATE;
2074 [CCode (cheader_filename = "sys/mman.h")]
2075 public const int MS_SYNC;
2078 [CCode (cname = "FILE", free_function = "fclose", cheader_filename = "stdio.h")]
2080 [CCode (cname = "EOF", cheader_filename = "stdio.h")]
2081 public const int EOF;
2082 [CCode (cname = "SEEK_SET", cheader_filename = "stdio.h")]
2083 public const int SEEK_SET;
2084 [CCode (cname = "SEEK_CUR", cheader_filename = "stdio.h")]
2085 public const int SEEK_CUR;
2086 [CCode (cname = "SEEK_END", cheader_filename = "stdio.h")]
2087 public const int SEEK_END;
2089 [CCode (cname = "fopen")]
2090 public static FILE? open (string path, string mode);
2091 [CCode (cname = "fdopen")]
2092 public static FILE? fdopen (int fildes, string mode);
2093 [CCode (cname = "popen")]
2094 public static FILE? popen (string command, string mode);
2096 [CCode (cname = "fprintf")]
2098 public void printf (string format, ...);
2099 [CCode (cname = "fputc", instance_pos = -1)]
2100 public void putc (char c);
2101 [CCode (cname = "fputs", instance_pos = -1)]
2102 public void puts (string s);
2103 [CCode (cname = "fgetc")]
2105 [CCode (cname = "fgets", instance_pos = -1)]
2106 public unowned string gets (char[] s);
2107 [CCode (cname = "feof")]
2109 [CCode (cname = "fscanf"), ScanfFormat]
2110 public int scanf (string format, ...);
2111 [CCode (cname = "fflush")]
2112 public int flush ();
2113 [CCode (cname = "fseek")]
2114 public int seek (long offset, int whence);
2115 [CCode (cname = "ftell")]
2116 public long tell ();
2117 [CCode (cname = "rewind")]
2118 public void rewind ();
2119 [CCode (cname = "fileno")]
2120 public int fileno ();
2121 [CCode (cname = "ferror")]
2122 public int error ();
2123 [CCode (cname = "clearerr")]
2124 public void clearerr ();
2127 public static FILE stderr;
2128 public static FILE stdout;
2129 public static FILE stdin;