DEADSOFTWARE

updated build scripts
[cpc.git] / src / native / linux / 486 / C99 / Mod / time.cp
1 MODULE C99time ['librt.so.1'];
3 (* generated by genposix.sh, do not modify *)
5 IMPORT SYSTEM, C99types, C99sys_types, C99locale;
7 TYPE
8 char* = C99types.char;
9 signed_char* = C99types.signed_char;
10 unsigned_char* = C99types.unsigned_char;
11 short* = C99types.short;
12 short_int* = C99types.short_int;
13 signed_short* = C99types.signed_short;
14 signed_short_int* = C99types.signed_short_int;
15 unsigned_short* = C99types.unsigned_short;
16 unsigned_short_int* = C99types.unsigned_short_int;
17 int* = C99types.int;
18 signed* = C99types.signed;
19 signed_int* = C99types.signed_int;
20 unsigned* = C99types.unsigned;
21 unsigned_int* = C99types.unsigned_int;
22 long* = C99types.long;
23 long_int* = C99types.long_int;
24 signed_long* = C99types.signed_long;
25 signed_long_int* = C99types.signed_long_int;
26 unsigned_long* = C99types.unsigned_long;
27 unsigned_long_int* = C99types.unsigned_long_int;
28 long_long* = C99types.long_long;
29 long_long_int* = C99types.long_long_int;
30 signed_long_long* = C99types.signed_long_long;
31 signed_long_long_int* = C99types.signed_long_long_int;
32 unsigned_long_long* = C99types.unsigned_long_long;
33 unsigned_long_long_int* = C99types.unsigned_long_long_int;
34 float* = C99types.float;
35 double* = C99types.double;
36 long_double* = C99types.long_double;
38 TYPE
39 clock_t* = C99sys_types.clock_t;
40 size_t* = C99sys_types.size_t;
41 time_t* = C99sys_types.time_t;
42 clockid_t* = C99sys_types.clockid_t;
43 timer_t* = C99sys_types.timer_t;
44 pid_t* = C99sys_types.pid_t;
46 TYPE
47 locale_t* = C99locale.locale_t;
49 TYPE
50 Pstruct_tm* = POINTER TO struct_tm;
51 struct_tm* = RECORD [noalign] (* 44 *)
52 tm_sec*: int; (* 0+4 *)
53 tm_min*: int; (* 4+4 *)
54 tm_hour*: int; (* 8+4 *)
55 tm_mday*: int; (* 12+4 *)
56 tm_mon*: int; (* 16+4 *)
57 tm_year*: int; (* 20+4 *)
58 tm_wday*: int; (* 24+4 *)
59 tm_yday*: int; (* 28+4 *)
60 tm_isdst*: int; (* 32+4 *)
61 _____align0_____: ARRAY 8 OF BYTE;
62 END;
64 TYPE
65 Pstruct_timespec* = POINTER TO struct_timespec;
66 struct_timespec* = RECORD [noalign] (* 8 *)
67 tv_sec*: time_t; (* 0+4 *)
68 tv_nsec*: long; (* 4+4 *)
69 END;
71 TYPE
72 Pstruct_itimerspec* = POINTER TO struct_itimerspec;
73 struct_itimerspec* = RECORD [noalign] (* 16 *)
74 it_interval*: struct_timespec; (* 0+8 *)
75 it_value*: struct_timespec; (* 8+8 *)
76 END;
78 CONST
79 CLOCKS_PER_SEC* = 1000000;
81 CONST
82 CLOCK_MONOTONIC* = 1;
83 CLOCK_PROCESS_CPUTIME_ID* = 2;
84 CLOCK_REALTIME* = 0;
85 CLOCK_THREAD_CPUTIME_ID* = 3;
87 CONST
88 TIMER_ABSTIME* = 1;
90 PROCEDURE [ccall] asctime* (IN tm: struct_tm): POINTER TO ARRAY [untagged] OF SHORTCHAR;
91 PROCEDURE [ccall] asctime_r* (IN tm: struct_tm; buf: POINTER TO ARRAY [untagged] OF SHORTCHAR): POINTER TO ARRAY [untagged] OF SHORTCHAR;
92 PROCEDURE [ccall] clock* (): clock_t;
93 PROCEDURE [ccall] clock_getcpuclockid* (pid: pid_t; VAR clock_id: clockid_t): int;
94 PROCEDURE [ccall] clock_getres* (clk_id: clockid_t; VAR res: struct_timespec): int;
95 PROCEDURE [ccall] clock_gettime* (clk_id: clockid_t; VAR res: struct_timespec): int;
96 PROCEDURE [ccall] clock_nanosleep* (clock_id: clockid_t; falgs: int; IN [nil] rqtp: struct_timespec; VAR [nil] rmtp: struct_timespec): int;
97 PROCEDURE [ccall] clock_settime* (clk_id: clockid_t; IN res: struct_timespec): int;
98 PROCEDURE [ccall] ctime* (VAR timep: time_t): POINTER TO ARRAY [untagged] OF SHORTCHAR;
99 PROCEDURE [ccall] ctime_r* (VAR timep: time_t; buf: POINTER TO ARRAY [untagged] OF SHORTCHAR): POINTER TO ARRAY [untagged] OF SHORTCHAR;
100 PROCEDURE [ccall] difftime* (time0, time1: time_t): double;
101 PROCEDURE [ccall] getdate* (IN string: ARRAY [untagged] OF SHORTCHAR): Pstruct_tm;
102 PROCEDURE [ccall] gmtime* (VAR timep: time_t): Pstruct_tm;
103 PROCEDURE [ccall] gmtime_r* (VAR timep: time_t; VAR result: struct_tm): Pstruct_tm;
104 PROCEDURE [ccall] localtime* (VAR timep: time_t): Pstruct_tm;
105 PROCEDURE [ccall] localtime_r* (VAR timep: time_t; VAR result: struct_tm): Pstruct_tm;
106 PROCEDURE [ccall] mktime* (VAR tm: struct_tm): time_t;
107 PROCEDURE [ccall] nanosleep* (IN [nil] rqtp: struct_timespec; VAR [nil] rmtp: struct_timespec): int;
108 PROCEDURE [ccall] strftime* (VAR s: ARRAY [untagged] OF SHORTCHAR; max: size_t; IN format: ARRAY [untagged] OF SHORTCHAR; IN tm: struct_tm): size_t;
109 PROCEDURE [ccall] strftime_l* (VAR s: ARRAY [untagged] OF SHORTCHAR; max: size_t; IN format: ARRAY [untagged] OF SHORTCHAR; IN tm: struct_tm; locale: locale_t): size_t;
110 PROCEDURE [ccall] strptime* (IN s, format: ARRAY [untagged] OF SHORTCHAR; VAR tm: struct_tm): POINTER TO ARRAY [untagged] OF SHORTCHAR;
111 PROCEDURE [ccall] time* (VAR [nil] tloc: time_t): time_t;
112 PROCEDURE [ccall] timer_delete* (timerid: timer_t): int;
113 PROCEDURE [ccall] timer_getoverrun* (timerid: timer_t): int;
114 PROCEDURE [ccall] timer_gettime* (timerid: timer_t; VAR value: struct_itimerspec): int;
115 PROCEDURE [ccall] timer_settime* (timerid: timer_t; flags: int; IN value: struct_itimerspec; VAR [nil] ovalue: struct_itimerspec): int;
116 PROCEDURE [ccall] tzset* ;
118 END C99time.