3 #ifdef __need_malloc_and_calloc
8 #include <stdlib/stdlib.h>
10 /* Now define the internal interfaces. */
11 #ifndef __Need_M_And_C
13 libc_hidden_proto (exit)
14 libc_hidden_proto (abort)
15 libc_hidden_proto (getenv)
16 libc_hidden_proto (bsearch)
17 libc_hidden_proto (qsort)
18 libc_hidden_proto (ecvt_r)
19 libc_hidden_proto (fcvt_r)
20 libc_hidden_proto (qecvt_r)
21 libc_hidden_proto (qfcvt_r)
22 libc_hidden_proto (lrand48_r)
23 libc_hidden_proto (wctomb)
24 libc_hidden_proto (__secure_getenv)
25 libc_hidden_proto (__strtof_internal)
26 libc_hidden_proto (__strtod_internal)
27 libc_hidden_proto (__strtold_internal)
28 libc_hidden_proto (__strtol_internal)
29 libc_hidden_proto (__strtoll_internal)
30 libc_hidden_proto (__strtoul_internal)
31 libc_hidden_proto (__strtoull_internal)
33 extern long int __random (void);
34 extern void __srandom (unsigned int __seed);
35 extern char *__initstate (unsigned int __seed, char *__statebuf,
37 extern char *__setstate (char *__statebuf);
38 extern int __random_r (struct random_data *__buf, int32_t *__result);
39 extern int __srandom_r (unsigned int __seed, struct random_data *__buf);
40 extern int __initstate_r (unsigned int __seed, char *__statebuf,
41 size_t __statelen, struct random_data *__buf);
42 extern int __setstate_r (char *__statebuf, struct random_data *__buf);
43 extern int __rand_r (unsigned int *__seed);
44 extern int __erand48_r (unsigned short int __xsubi[3],
45 struct drand48_data *__buffer, double *__result);
46 extern int __nrand48_r (unsigned short int __xsubi[3],
47 struct drand48_data *__buffer,
49 extern int __jrand48_r (unsigned short int __xsubi[3],
50 struct drand48_data *__buffer,
52 extern int __srand48_r (long int __seedval,
53 struct drand48_data *__buffer);
54 extern int __seed48_r (unsigned short int __seed16v[3],
55 struct drand48_data *__buffer);
56 extern int __lcong48_r (unsigned short int __param[7],
57 struct drand48_data *__buffer);
59 /* Internal function to compute next state of the generator. */
60 extern int __drand48_iterate (unsigned short int __xsubi[3],
61 struct drand48_data *__buffer);
63 /* Global state for non-reentrant functions. Defined in drand48-iter.c. */
64 extern struct drand48_data __libc_drand48_data attribute_hidden;
66 extern int __setenv (__const char *__name, __const char *__value,
68 extern int __unsetenv (__const char *__name);
69 extern int __clearenv (void);
70 extern char *__canonicalize_file_name (__const char *__name);
71 extern char *__realpath (__const char *__name, char *__resolved);
72 extern int __ptsname_r (int __fd, char *__buf, size_t __buflen);
73 extern int __getpt (void);
74 extern int __posix_openpt (int __oflag);
76 extern int __add_to_environ (const char *name, const char *value,
77 const char *combines, int replace);
79 extern void _quicksort (void *const pbase, size_t total_elems,
80 size_t size, __compar_fn_t cmp);
82 extern int __on_exit (void (*__func) (int __status, void *__arg), void *__arg);
84 extern int __cxa_atexit (void (*func) (void *), void *arg, void *d);
85 extern int __cxa_atexit_internal (void (*func) (void *), void *arg, void *d)
88 extern void __cxa_finalize (void *d);
90 extern int __posix_memalign (void **memptr, size_t alignment, size_t size)
92 extern void *__libc_memalign (size_t alignment, size_t size)
95 extern int __libc_system (const char *line);
97 extern double ____strtod_l_internal (__const char *__restrict __nptr,
98 char **__restrict __endptr, int __group,
99 __locale_t __loc) __THROW;
100 extern float ____strtof_l_internal (__const char *__restrict __nptr,
101 char **__restrict __endptr, int __group,
102 __locale_t __loc) __THROW;
103 extern long double ____strtold_l_internal (__const char *__restrict __nptr,
104 char **__restrict __endptr,
105 int __group, __locale_t __loc)
107 extern long int ____strtol_l_internal (__const char *__restrict __nptr,
108 char **__restrict __endptr,
109 int __base, int __group,
110 __locale_t __loc) __THROW;
111 extern unsigned long int ____strtoul_l_internal (__const char *
113 char **__restrict __endptr,
114 int __base, int __group,
115 __locale_t __loc) __THROW;
117 extern long long int ____strtoll_l_internal (__const char *__restrict __nptr,
118 char **__restrict __endptr,
119 int __base, int __group,
120 __locale_t __loc) __THROW;
122 extern unsigned long long int ____strtoull_l_internal (__const char *
126 int __base, int __group,
130 libc_hidden_proto (____strtof_l_internal)
131 libc_hidden_proto (____strtod_l_internal)
132 libc_hidden_proto (____strtold_l_internal)
133 libc_hidden_proto (____strtol_l_internal)
134 libc_hidden_proto (____strtoll_l_internal)
135 libc_hidden_proto (____strtoul_l_internal)
136 libc_hidden_proto (____strtoull_l_internal)
138 extern __inline double
139 __strtod_l (__const char *__restrict __nptr, char **__restrict __endptr,
140 __locale_t __loc) __THROW
142 return ____strtod_l_internal (__nptr, __endptr, 0, __loc);
144 extern __inline long int
145 __strtol_l (__const char *__restrict __nptr, char **__restrict __endptr,
146 int __base, __locale_t __loc) __THROW
148 return ____strtol_l_internal (__nptr, __endptr, __base, 0, __loc);
150 extern __inline unsigned long int
151 __strtoul_l (__const char *__restrict __nptr, char **__restrict __endptr,
152 int __base, __locale_t __loc) __THROW
154 return ____strtoul_l_internal (__nptr, __endptr, __base, 0, __loc);
156 extern __inline float
157 __strtof_l (__const char *__restrict __nptr, char **__restrict __endptr,
158 __locale_t __loc) __THROW
160 return ____strtof_l_internal (__nptr, __endptr, 0, __loc);
162 extern __inline long double
163 __strtold_l (__const char *__restrict __nptr, char **__restrict __endptr,
164 __locale_t __loc) __THROW
166 return ____strtold_l_internal (__nptr, __endptr, 0, __loc);
168 __extension__ extern __inline long long int
169 __strtoll_l (__const char *__restrict __nptr, char **__restrict __endptr,
170 int __base, __locale_t __loc) __THROW
172 return ____strtoll_l_internal (__nptr, __endptr, __base, 0, __loc);
174 __extension__ extern __inline unsigned long long int
175 __strtoull_l (__const char * __restrict __nptr, char **__restrict __endptr,
176 int __base, __locale_t __loc) __THROW
178 return ____strtoull_l_internal (__nptr, __endptr, __base, 0, __loc);
184 # define MB_CUR_MAX (_NL_CURRENT_WORD (LC_CTYPE, _NL_CTYPE_MB_CUR_MAX))
186 # define __cxa_atexit(func, arg, d) INTUSE(__cxa_atexit) (func, arg, d)
191 extern void * __default_morecore (ptrdiff_t);
192 libc_hidden_proto (__default_morecore)
194 #undef __Need_M_And_C
196 #endif /* include/stdlib.h */