DEADSOFTWARE

add osx-ppc support via cpfront
[cpc.git] / src / cpfront / osx / powerpc / Posix / Mod / Cfcntl.cp
1 MODULE PosixCfcntl ['fcntl.h'];
3 (* generated by genposix.sh, do not modify *)
5 IMPORT SYSTEM, PosixCtypes, PosixCsys_types;
7 TYPE
8 char* = PosixCtypes.char;
9 signed_char* = PosixCtypes.signed_char;
10 unsigned_char* = PosixCtypes.unsigned_char;
11 short* = PosixCtypes.short;
12 short_int* = PosixCtypes.short_int;
13 signed_short* = PosixCtypes.signed_short;
14 signed_short_int* = PosixCtypes.signed_short_int;
15 unsigned_short* = PosixCtypes.unsigned_short;
16 unsigned_short_int* = PosixCtypes.unsigned_short_int;
17 int* = PosixCtypes.int;
18 signed* = PosixCtypes.signed;
19 signed_int* = PosixCtypes.signed_int;
20 unsigned* = PosixCtypes.unsigned;
21 unsigned_int* = PosixCtypes.unsigned_int;
22 long* = PosixCtypes.long;
23 long_int* = PosixCtypes.long_int;
24 signed_long* = PosixCtypes.signed_long;
25 signed_long_int* = PosixCtypes.signed_long_int;
26 unsigned_long* = PosixCtypes.unsigned_long;
27 unsigned_long_int* = PosixCtypes.unsigned_long_int;
28 long_long* = PosixCtypes.long_long;
29 long_long_int* = PosixCtypes.long_long_int;
30 signed_long_long* = PosixCtypes.signed_long_long;
31 signed_long_long_int* = PosixCtypes.signed_long_long_int;
32 unsigned_long_long* = PosixCtypes.unsigned_long_long;
33 unsigned_long_long_int* = PosixCtypes.unsigned_long_long_int;
34 float* = PosixCtypes.float;
35 double* = PosixCtypes.double;
36 long_double* = PosixCtypes.long_double;
38 CONST
39 F_DUPFD* = 0;
40 F_GETFD* = 1;
41 F_SETFD* = 2;
42 F_GETFL* = 3;
43 F_SETFL* = 4;
44 F_GETLK* = 7;
45 F_SETLK* = 8;
46 F_SETLKW* = 9;
47 F_GETOWN* = 5;
48 F_SETOWN* = 6;
50 CONST
51 F_RDLCK* = 1;
52 F_UNLCK* = 2;
53 F_WRLCK* = 3;
55 CONST
56 SEEK_SET* = 0;
57 SEEK_CUR* = 1;
58 SEEK_END* = 2;
60 CONST
61 O_CREAT* = 512;
62 O_DIRECTORY* = 1048576;
63 O_EXCL* = 2048;
64 O_NOCTTY* = 131072;
65 O_NOFOLLOW* = 256;
66 O_TRUNC* = 1024;
67 O_APPEND* = 8;
68 O_NONBLOCK* = 4;
69 O_SYNC* = 128;
70 O_ACCMODE* = 3;
71 O_RDONLY* = 0;
72 O_RDWR* = 2;
73 O_WRONLY* = 1;
75 TYPE
76 Pstruct_flock* = POINTER TO struct_flock;
77 struct_flock* ['struct flock'] = RECORD [noalign] (* 24 *)
78 l_start*: off_t; (* 0+8 *)
79 l_len*: off_t; (* 8+8 *)
80 l_pid*: pid_t; (* 16+4 *)
81 l_type*: short; (* 20+2 *)
82 l_whence*: short; (* 22+2 *)
83 END;
85 TYPE
86 mode_t* = PosixCsys_types.mode_t;
87 off_t* = PosixCsys_types.off_t;
88 pid_t* = PosixCsys_types.pid_t;
90 PROCEDURE [ccall] creat* (IN pathname: ARRAY [untagged] OF SHORTCHAR; mode: mode_t): int;
91 PROCEDURE [ccall] fcntl* (fildes, cmd, arg: int): int;
92 PROCEDURE [ccall] open* (IN pathname: ARRAY [untagged] OF SHORTCHAR; flags: int; mode: mode_t): int;
93 PROCEDURE [ccall] openat* (fddir: int; IN pathname: ARRAY [untagged] OF SHORTCHAR; flags: int; mode: mode_t): int;
94 PROCEDURE [ccall] posix_fadvise* (fd: int; offset, len: off_t; advice: int): int;
95 PROCEDURE [ccall] posix_fallocate* (fd: int; offset, len: off_t): int;
97 END PosixCfcntl.