fix type discovery
[m6w6/ext-psi] / m4 / stdlib.m4
1 PSI_CHECK_STDLIB() {
2 AC_CHECK_HEADERS(stdlib.h)
3
4 PSI_STRUCT(div_t, [
5 int quot,
6 int rem
7 ])
8 PSI_STRUCT(ldiv_t, [
9 long quot,
10 long rem
11 ])
12
13 PSI_CONST(EXIT_FAILURE, int)
14 PSI_CONST(EXIT_SUCCESS, int)
15 PSI_CONST(RAND_MAX, int)
16
17 PSI_MACRO(int MB_CUR_MAX)
18
19 PSI_DECL(void _Exit, [(int status)])
20 PSI_DECL(void abort, [()])
21 PSI_DECL(int abs, [(int n)])
22 PSI_DECL(double atof, [(char *str)])
23 PSI_DECL(int atoi, [(char *str)])
24 PSI_DECL(long atol, [(char *str)])
25 dnl PSI_DECL(div_t div, [(int numerator, int denominator)])
26 PSI_DECL(double drand48, [()])
27 PSI_DECL(double erand48, [(unsigned short xsubi@<:@3@:>@)])
28 PSI_DECL(void exit, [(int status)])
29 PSI_DECL(void free, [(void *ptr)])
30 PSI_DECL(char *getenv, [(char *var)])
31 PSI_DECL(int grantpt, [(int fd)])
32 PSI_DECL(char *initstate, [(unsigned int seed, char *state, size_t n)])
33 PSI_DECL(long jrand48, [(unsigned short xsubi@<:@3@:>@)])
34 PSI_DECL(long labs, [(long l)])
35 PSI_DECL(void lcong48, [(unsigned short param@<:@7@:>@)])
36 dnl PSI_DECL(ldiv_t ldiv, [(long numerator, long denominator)])
37 PSI_DECL(long lrand48, [()])
38 PSI_DECL(int mblen, [(const char *s, size_t n)])
39 PSI_DECL(size_t mbstowcs, [(wchar_t *dest, char *src, size_t n)])
40 PSI_DECL(int mbtowc, [(wchar_t *pwc, char *s, size_t n)])
41 PSI_DECL(char *mkdtemp, [(char *template)])
42 PSI_DECL(char *mkdstemp, [(char *template)])
43 PSI_DECL(long mrand48, [()])
44 PSI_DECL(long nrand48, [(unsigned short xsubi@<:@3@:>@)])
45 PSI_DECL(int posix_openpt, [(int flags)])
46 PSI_DECL(char *ptsname, [(int fd)])
47 PSI_DECL(char *pstname_r, [(int fd, char *buf, size_t buflen)])
48 PSI_DECL(int putenv, [(char *var)])
49 PSI_DECL(int rand, [()])
50 PSI_DECL(int rand_r, [(unsigned *seed_p)])
51 PSI_DECL(long random, [()])
52 PSI_DECL(char *realpath, [(char *path, char *resolved)])
53 PSI_DECL(unsigned short *seed48, [(unsigned short seed16v@<:@3@:>@)])
54 PSI_DECL(int setenv, [(char *var)])
55 PSI_DECL(void setkey, [(char *key)])
56 PSI_DECL(char *setstate, [(char *state)])
57 PSI_DECL(void srand, [(unsigned seed)])
58 PSI_DECL(void srand48, [(long seed)])
59 PSI_DECL(void srandom, [(unsigned seed)])
60 PSI_DECL(double strtod, [(char *nptr, char **endptr)])
61 PSI_DECL(float strtof, [(char *nptr, char **endptr)])
62 PSI_DECL(long strtol, [(char *nptr, char **endptr)])
63 PSI_DECL(unsigned long strtoul, [(char *nptr, char **endptr)])
64 PSI_DECL(int system, [(char *command)])
65 PSI_DECL(int unlockpt, [(int fd)])
66 PSI_DECL(int unsetenv, [(char *var)])
67 PSI_DECL(size_t wcstombs, [(char *dest, wchar_t *src, size_t n)])
68 PSI_DECL(int wctomb, [(char *s, wchar_t wc)])
69 }