~ubuntu-branches/ubuntu/precise/wget/precise-proposed

« back to all changes in this revision

Viewing changes to lib/stdlib.in.h

  • Committer: Bazaar Package Importer
  • Author(s): Steve Langasek
  • Date: 2011-10-19 00:00:09 UTC
  • mfrom: (2.1.13 sid)
  • Revision ID: james.westby@ubuntu.com-20111019000009-8p33w3wz4b1rdri0
Tags: 1.13-1ubuntu1
* Merge from Debian unstable, remaining changes:
  - Add wget-udeb to ship wget.gnu as alternative to busybox wget
    implementation.
  - Depend on libssl-dev 0.9.8k-7ubuntu4 (LP: #503339)
* Dropped changes, superseded in Debian:
  - Keep build dependencies in main:
    + debian/control: remove info2man build-dep
    + debian/patches/series: disable wget-infopod_generated_manpage
  - Mark wget Multi-Arch: foreign, so packages that aren't of the same arch
    can depend on it.
* Pass --with-ssl=openssl; we don't want to use gnutls, there's no udeb for
  it.
* Add a second build pass for the udeb, so we can build without libidn.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* A GNU-like <stdlib.h>.
2
2
 
3
 
   Copyright (C) 1995, 2001-2004, 2006-2009 Free Software Foundation, Inc.
 
3
   Copyright (C) 1995, 2001-2004, 2006-2011 Free Software Foundation, Inc.
4
4
 
5
5
   This program is free software: you can redistribute it and/or modify
6
6
   it under the terms of the GNU General Public License as published by
18
18
#if __GNUC__ >= 3
19
19
@PRAGMA_SYSTEM_HEADER@
20
20
#endif
 
21
@PRAGMA_COLUMNS@
21
22
 
22
23
#if defined __need_malloc_and_calloc
23
24
/* Special invocation convention inside glibc header files.  */
27
28
#else
28
29
/* Normal invocation convention.  */
29
30
 
30
 
#ifndef _GL_STDLIB_H
 
31
#ifndef _@GUARD_PREFIX@_STDLIB_H
31
32
 
32
33
/* The include_next requires a split double-inclusion guard.  */
33
34
#@INCLUDE_NEXT@ @NEXT_STDLIB_H@
34
35
 
35
 
#ifndef _GL_STDLIB_H
36
 
#define _GL_STDLIB_H
 
36
#ifndef _@GUARD_PREFIX@_STDLIB_H
 
37
#define _@GUARD_PREFIX@_STDLIB_H
37
38
 
38
39
/* NetBSD 5.0 mis-defines NULL.  */
39
40
#include <stddef.h>
40
41
 
 
42
/* MirBSD 10 defines WEXITSTATUS in <sys/wait.h>, not in <stdlib.h>.  */
 
43
#if @GNULIB_SYSTEM_POSIX@ && !defined WEXITSTATUS
 
44
# include <sys/wait.h>
 
45
#endif
 
46
 
41
47
/* Solaris declares getloadavg() in <sys/loadavg.h>.  */
42
 
#if @GNULIB_GETLOADAVG@ && @HAVE_SYS_LOADAVG_H@
 
48
#if (@GNULIB_GETLOADAVG@ || defined GNULIB_POSIXCHECK) && @HAVE_SYS_LOADAVG_H@
43
49
# include <sys/loadavg.h>
44
50
#endif
45
51
 
 
52
#if @GNULIB_RANDOM_R@
 
53
 
46
54
/* OSF/1 5.1 declares 'struct random_data' in <random.h>, which is included
47
 
   from <stdlib.h> if _REENTRANT is defined.  Include it always.  */
48
 
#if @HAVE_RANDOM_H@
49
 
# include <random.h>
50
 
#endif
51
 
 
52
 
#if @GNULIB_RANDOM_R@ || !@HAVE_STRUCT_RANDOM_DATA@
53
 
# include <stdint.h>
54
 
#endif
55
 
 
56
 
#if !@HAVE_STRUCT_RANDOM_DATA@
 
55
   from <stdlib.h> if _REENTRANT is defined.  Include it whenever we need
 
56
   'struct random_data'.  */
 
57
# if @HAVE_RANDOM_H@
 
58
#  include <random.h>
 
59
# endif
 
60
 
 
61
# if !@HAVE_STRUCT_RANDOM_DATA@ || !@HAVE_RANDOM_R@
 
62
#  include <stdint.h>
 
63
# endif
 
64
 
 
65
# if !@HAVE_STRUCT_RANDOM_DATA@
 
66
/* Define 'struct random_data'.
 
67
   But allow multiple gnulib generated <stdlib.h> replacements to coexist.  */
 
68
#  if !GNULIB_defined_struct_random_data
57
69
struct random_data
58
70
{
59
 
  int32_t *fptr;                /* Front pointer.  */
60
 
  int32_t *rptr;                /* Rear pointer.  */
61
 
  int32_t *state;               /* Array of state values.  */
62
 
  int rand_type;                /* Type of random number generator.  */
63
 
  int rand_deg;                 /* Degree of random number generator.  */
64
 
  int rand_sep;                 /* Distance between front and rear.  */
65
 
  int32_t *end_ptr;             /* Pointer behind state table.  */
 
71
  int32_t *fptr;                /* Front pointer.  */
 
72
  int32_t *rptr;                /* Rear pointer.  */
 
73
  int32_t *state;               /* Array of state values.  */
 
74
  int rand_type;                /* Type of random number generator.  */
 
75
  int rand_deg;                 /* Degree of random number generator.  */
 
76
  int rand_sep;                 /* Distance between front and rear.  */
 
77
  int32_t *end_ptr;             /* Pointer behind state table.  */
66
78
};
67
 
#endif
68
 
 
69
 
/* The definition of GL_LINK_WARNING is copied here.  */
 
79
#   define GNULIB_defined_struct_random_data 1
 
80
#  endif
 
81
# endif
 
82
#endif
 
83
 
 
84
#if (@GNULIB_MKSTEMP@ || @GNULIB_MKSTEMPS@ || @GNULIB_GETSUBOPT@ || defined GNULIB_POSIXCHECK) && ! defined __GLIBC__ && !((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__)
 
85
/* On MacOS X 10.3, only <unistd.h> declares mkstemp.  */
 
86
/* On MacOS X 10.5, only <unistd.h> declares mkstemps.  */
 
87
/* On Cygwin 1.7.1, only <unistd.h> declares getsubopt.  */
 
88
/* But avoid namespace pollution on glibc systems and native Windows.  */
 
89
# include <unistd.h>
 
90
#endif
 
91
 
 
92
/* The definition of _Noreturn is copied here.  */
 
93
 
 
94
/* The definitions of _GL_FUNCDECL_RPL etc. are copied here.  */
 
95
 
 
96
/* The definition of _GL_ARG_NONNULL is copied here.  */
 
97
 
 
98
/* The definition of _GL_WARN_ON_USE is copied here.  */
70
99
 
71
100
 
72
101
/* Some systems do not define EXIT_*, despite otherwise supporting C89.  */
83
112
#endif
84
113
 
85
114
 
86
 
#ifdef __cplusplus
87
 
extern "C" {
88
 
#endif
89
 
 
90
 
 
91
 
#if @GNULIB_MALLOC_POSIX@
92
 
# if !@HAVE_MALLOC_POSIX@
93
 
#  undef malloc
94
 
#  define malloc rpl_malloc
95
 
extern void * malloc (size_t size);
96
 
# endif
97
 
#elif defined GNULIB_POSIXCHECK
98
 
# undef malloc
99
 
# define malloc(s) \
100
 
    (GL_LINK_WARNING ("malloc is not POSIX compliant everywhere - " \
101
 
                      "use gnulib module malloc-posix for portability"), \
102
 
     malloc (s))
103
 
#endif
104
 
 
105
 
 
106
 
#if @GNULIB_REALLOC_POSIX@
107
 
# if !@HAVE_REALLOC_POSIX@
108
 
#  undef realloc
109
 
#  define realloc rpl_realloc
110
 
extern void * realloc (void *ptr, size_t size);
111
 
# endif
112
 
#elif defined GNULIB_POSIXCHECK
113
 
# undef realloc
114
 
# define realloc(p,s) \
115
 
    (GL_LINK_WARNING ("realloc is not POSIX compliant everywhere - " \
116
 
                      "use gnulib module realloc-posix for portability"), \
117
 
     realloc (p, s))
118
 
#endif
119
 
 
120
 
 
121
 
#if @GNULIB_CALLOC_POSIX@
122
 
# if !@HAVE_CALLOC_POSIX@
123
 
#  undef calloc
124
 
#  define calloc rpl_calloc
125
 
extern void * calloc (size_t nmemb, size_t size);
126
 
# endif
127
 
#elif defined GNULIB_POSIXCHECK
128
 
# undef calloc
129
 
# define calloc(n,s) \
130
 
    (GL_LINK_WARNING ("calloc is not POSIX compliant everywhere - " \
131
 
                      "use gnulib module calloc-posix for portability"), \
132
 
     calloc (n, s))
 
115
#if @GNULIB__EXIT@
 
116
/* Terminate the current process with the given return code, without running
 
117
   the 'atexit' handlers.  */
 
118
# if !@HAVE__EXIT@
 
119
_GL_FUNCDECL_SYS (_Exit, _Noreturn void, (int status));
 
120
# endif
 
121
_GL_CXXALIAS_SYS (_Exit, void, (int status));
 
122
_GL_CXXALIASWARN (_Exit);
 
123
#elif defined GNULIB_POSIXCHECK
 
124
# undef _Exit
 
125
# if HAVE_RAW_DECL__EXIT
 
126
_GL_WARN_ON_USE (_Exit, "_Exit is unportable - "
 
127
                 "use gnulib module _Exit for portability");
 
128
# endif
133
129
#endif
134
130
 
135
131
 
136
132
#if @GNULIB_ATOLL@
137
 
# if !@HAVE_ATOLL@
138
133
/* Parse a signed decimal integer.
139
134
   Returns the value of the integer.  Errors are not detected.  */
140
 
extern long long atoll (const char *string);
 
135
# if !@HAVE_ATOLL@
 
136
_GL_FUNCDECL_SYS (atoll, long long, (const char *string) _GL_ARG_NONNULL ((1)));
141
137
# endif
 
138
_GL_CXXALIAS_SYS (atoll, long long, (const char *string));
 
139
_GL_CXXALIASWARN (atoll);
142
140
#elif defined GNULIB_POSIXCHECK
143
141
# undef atoll
144
 
# define atoll(s) \
145
 
    (GL_LINK_WARNING ("atoll is unportable - " \
146
 
                      "use gnulib module atoll for portability"), \
147
 
     atoll (s))
148
 
#endif
149
 
 
 
142
# if HAVE_RAW_DECL_ATOLL
 
143
_GL_WARN_ON_USE (atoll, "atoll is unportable - "
 
144
                 "use gnulib module atoll for portability");
 
145
# endif
 
146
#endif
 
147
 
 
148
#if @GNULIB_CALLOC_POSIX@
 
149
# if @REPLACE_CALLOC@
 
150
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
151
#   undef calloc
 
152
#   define calloc rpl_calloc
 
153
#  endif
 
154
_GL_FUNCDECL_RPL (calloc, void *, (size_t nmemb, size_t size));
 
155
_GL_CXXALIAS_RPL (calloc, void *, (size_t nmemb, size_t size));
 
156
# else
 
157
_GL_CXXALIAS_SYS (calloc, void *, (size_t nmemb, size_t size));
 
158
# endif
 
159
_GL_CXXALIASWARN (calloc);
 
160
#elif defined GNULIB_POSIXCHECK
 
161
# undef calloc
 
162
/* Assume calloc is always declared.  */
 
163
_GL_WARN_ON_USE (calloc, "calloc is not POSIX compliant everywhere - "
 
164
                 "use gnulib module calloc-posix for portability");
 
165
#endif
 
166
 
 
167
#if @GNULIB_CANONICALIZE_FILE_NAME@
 
168
# if @REPLACE_CANONICALIZE_FILE_NAME@
 
169
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
170
#   define canonicalize_file_name rpl_canonicalize_file_name
 
171
#  endif
 
172
_GL_FUNCDECL_RPL (canonicalize_file_name, char *, (const char *name)
 
173
                                                  _GL_ARG_NONNULL ((1)));
 
174
_GL_CXXALIAS_RPL (canonicalize_file_name, char *, (const char *name));
 
175
# else
 
176
#  if !@HAVE_CANONICALIZE_FILE_NAME@
 
177
_GL_FUNCDECL_SYS (canonicalize_file_name, char *, (const char *name)
 
178
                                                  _GL_ARG_NONNULL ((1)));
 
179
#  endif
 
180
_GL_CXXALIAS_SYS (canonicalize_file_name, char *, (const char *name));
 
181
# endif
 
182
_GL_CXXALIASWARN (canonicalize_file_name);
 
183
#elif defined GNULIB_POSIXCHECK
 
184
# undef canonicalize_file_name
 
185
# if HAVE_RAW_DECL_CANONICALIZE_FILE_NAME
 
186
_GL_WARN_ON_USE (canonicalize_file_name,
 
187
                 "canonicalize_file_name is unportable - "
 
188
                 "use gnulib module canonicalize-lgpl for portability");
 
189
# endif
 
190
#endif
150
191
 
151
192
#if @GNULIB_GETLOADAVG@
152
 
# if !@HAVE_DECL_GETLOADAVG@
153
193
/* Store max(NELEM,3) load average numbers in LOADAVG[].
154
194
   The three numbers are the load average of the last 1 minute, the last 5
155
195
   minutes, and the last 15 minutes, respectively.
156
196
   LOADAVG is an array of NELEM numbers.  */
157
 
extern int getloadavg (double loadavg[], int nelem);
 
197
# if !@HAVE_DECL_GETLOADAVG@
 
198
_GL_FUNCDECL_SYS (getloadavg, int, (double loadavg[], int nelem)
 
199
                                   _GL_ARG_NONNULL ((1)));
158
200
# endif
 
201
_GL_CXXALIAS_SYS (getloadavg, int, (double loadavg[], int nelem));
 
202
_GL_CXXALIASWARN (getloadavg);
159
203
#elif defined GNULIB_POSIXCHECK
160
204
# undef getloadavg
161
 
# define getloadavg(l,n) \
162
 
    (GL_LINK_WARNING ("getloadavg is not portable - " \
163
 
                      "use gnulib module getloadavg for portability"), \
164
 
     getloadavg (l, n))
 
205
# if HAVE_RAW_DECL_GETLOADAVG
 
206
_GL_WARN_ON_USE (getloadavg, "getloadavg is not portable - "
 
207
                 "use gnulib module getloadavg for portability");
 
208
# endif
165
209
#endif
166
210
 
167
 
 
168
211
#if @GNULIB_GETSUBOPT@
169
212
/* Assuming *OPTIONP is a comma separated list of elements of the form
170
213
   "token" or "token=value", getsubopt parses the first of these elements.
178
221
   For more details see the POSIX:2001 specification.
179
222
   http://www.opengroup.org/susv3xsh/getsubopt.html */
180
223
# if !@HAVE_GETSUBOPT@
181
 
extern int getsubopt (char **optionp, char *const *tokens, char **valuep);
 
224
_GL_FUNCDECL_SYS (getsubopt, int,
 
225
                  (char **optionp, char *const *tokens, char **valuep)
 
226
                  _GL_ARG_NONNULL ((1, 2, 3)));
182
227
# endif
 
228
_GL_CXXALIAS_SYS (getsubopt, int,
 
229
                  (char **optionp, char *const *tokens, char **valuep));
 
230
_GL_CXXALIASWARN (getsubopt);
183
231
#elif defined GNULIB_POSIXCHECK
184
232
# undef getsubopt
185
 
# define getsubopt(o,t,v) \
186
 
    (GL_LINK_WARNING ("getsubopt is unportable - " \
187
 
                      "use gnulib module getsubopt for portability"), \
188
 
     getsubopt (o, t, v))
189
 
#endif
190
 
 
 
233
# if HAVE_RAW_DECL_GETSUBOPT
 
234
_GL_WARN_ON_USE (getsubopt, "getsubopt is unportable - "
 
235
                 "use gnulib module getsubopt for portability");
 
236
# endif
 
237
#endif
 
238
 
 
239
#if @GNULIB_GRANTPT@
 
240
/* Change the ownership and access permission of the slave side of the
 
241
   pseudo-terminal whose master side is specified by FD.  */
 
242
# if !@HAVE_GRANTPT@
 
243
_GL_FUNCDECL_SYS (grantpt, int, (int fd));
 
244
# endif
 
245
_GL_CXXALIAS_SYS (grantpt, int, (int fd));
 
246
_GL_CXXALIASWARN (grantpt);
 
247
#elif defined GNULIB_POSIXCHECK
 
248
# undef grantpt
 
249
# if HAVE_RAW_DECL_GRANTPT
 
250
_GL_WARN_ON_USE (ptsname, "grantpt is not portable - "
 
251
                 "use gnulib module grantpt for portability");
 
252
# endif
 
253
#endif
 
254
 
 
255
/* If _GL_USE_STDLIB_ALLOC is nonzero, the including module does not
 
256
   rely on GNU or POSIX semantics for malloc and realloc (for example,
 
257
   by never specifying a zero size), so it does not need malloc or
 
258
   realloc to be redefined.  */
 
259
#if @GNULIB_MALLOC_POSIX@
 
260
# if @REPLACE_MALLOC@
 
261
#  if !((defined __cplusplus && defined GNULIB_NAMESPACE) \
 
262
        || _GL_USE_STDLIB_ALLOC)
 
263
#   undef malloc
 
264
#   define malloc rpl_malloc
 
265
#  endif
 
266
_GL_FUNCDECL_RPL (malloc, void *, (size_t size));
 
267
_GL_CXXALIAS_RPL (malloc, void *, (size_t size));
 
268
# else
 
269
_GL_CXXALIAS_SYS (malloc, void *, (size_t size));
 
270
# endif
 
271
_GL_CXXALIASWARN (malloc);
 
272
#elif defined GNULIB_POSIXCHECK && !_GL_USE_STDLIB_ALLOC
 
273
# undef malloc
 
274
/* Assume malloc is always declared.  */
 
275
_GL_WARN_ON_USE (malloc, "malloc is not POSIX compliant everywhere - "
 
276
                 "use gnulib module malloc-posix for portability");
 
277
#endif
 
278
 
 
279
/* Convert a multibyte character to a wide character.  */
 
280
#if @GNULIB_MBTOWC@
 
281
# if @REPLACE_MBTOWC@
 
282
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
283
#   undef mbtowc
 
284
#   define mbtowc rpl_mbtowc
 
285
#  endif
 
286
_GL_FUNCDECL_RPL (mbtowc, int, (wchar_t *pwc, const char *s, size_t n));
 
287
_GL_CXXALIAS_RPL (mbtowc, int, (wchar_t *pwc, const char *s, size_t n));
 
288
# else
 
289
_GL_CXXALIAS_SYS (mbtowc, int, (wchar_t *pwc, const char *s, size_t n));
 
290
# endif
 
291
_GL_CXXALIASWARN (mbtowc);
 
292
#endif
191
293
 
192
294
#if @GNULIB_MKDTEMP@
193
 
# if !@HAVE_MKDTEMP@
194
295
/* Create a unique temporary directory from TEMPLATE.
195
296
   The last six characters of TEMPLATE must be "XXXXXX";
196
297
   they are replaced with a string that makes the directory name unique.
197
298
   Returns TEMPLATE, or a null pointer if it cannot get a unique name.
198
299
   The directory is created mode 700.  */
199
 
extern char * mkdtemp (char * /*template*/);
 
300
# if !@HAVE_MKDTEMP@
 
301
_GL_FUNCDECL_SYS (mkdtemp, char *, (char * /*template*/) _GL_ARG_NONNULL ((1)));
200
302
# endif
 
303
_GL_CXXALIAS_SYS (mkdtemp, char *, (char * /*template*/));
 
304
_GL_CXXALIASWARN (mkdtemp);
201
305
#elif defined GNULIB_POSIXCHECK
202
306
# undef mkdtemp
203
 
# define mkdtemp(t) \
204
 
    (GL_LINK_WARNING ("mkdtemp is unportable - " \
205
 
                      "use gnulib module mkdtemp for portability"), \
206
 
     mkdtemp (t))
 
307
# if HAVE_RAW_DECL_MKDTEMP
 
308
_GL_WARN_ON_USE (mkdtemp, "mkdtemp is unportable - "
 
309
                 "use gnulib module mkdtemp for portability");
 
310
# endif
207
311
#endif
208
312
 
209
 
 
210
313
#if @GNULIB_MKOSTEMP@
 
314
/* Create a unique temporary file from TEMPLATE.
 
315
   The last six characters of TEMPLATE must be "XXXXXX";
 
316
   they are replaced with a string that makes the file name unique.
 
317
   The flags are a bitmask, possibly including O_CLOEXEC (defined in <fcntl.h>)
 
318
   and O_TEXT, O_BINARY (defined in "binary-io.h").
 
319
   The file is then created, with the specified flags, ensuring it didn't exist
 
320
   before.
 
321
   The file is created read-write (mask at least 0600 & ~umask), but it may be
 
322
   world-readable and world-writable (mask 0666 & ~umask), depending on the
 
323
   implementation.
 
324
   Returns the open file descriptor if successful, otherwise -1 and errno
 
325
   set.  */
211
326
# if !@HAVE_MKOSTEMP@
212
 
/* Create a unique temporary file from TEMPLATE.
213
 
   The last six characters of TEMPLATE must be "XXXXXX";
214
 
   they are replaced with a string that makes the file name unique.
215
 
   The flags are a bitmask, possibly including O_CLOEXEC (defined in <fcntl.h>)
216
 
   and O_TEXT, O_BINARY (defined in "binary-io.h").
217
 
   The file is then created, with the specified flags, ensuring it didn't exist
218
 
   before.
219
 
   The file is created read-write (mask at least 0600 & ~umask), but it may be
220
 
   world-readable and world-writable (mask 0666 & ~umask), depending on the
221
 
   implementation.
222
 
   Returns the open file descriptor if successful, otherwise -1 and errno
223
 
   set.  */
224
 
extern int mkostemp (char * /*template*/, int /*flags*/);
 
327
_GL_FUNCDECL_SYS (mkostemp, int, (char * /*template*/, int /*flags*/)
 
328
                                 _GL_ARG_NONNULL ((1)));
225
329
# endif
 
330
_GL_CXXALIAS_SYS (mkostemp, int, (char * /*template*/, int /*flags*/));
 
331
_GL_CXXALIASWARN (mkostemp);
226
332
#elif defined GNULIB_POSIXCHECK
227
333
# undef mkostemp
228
 
# define mkostemp(t,f) \
229
 
    (GL_LINK_WARNING ("mkostemp is unportable - " \
230
 
                      "use gnulib module mkostemp for portability"), \
231
 
     mkostemp (t, f))
 
334
# if HAVE_RAW_DECL_MKOSTEMP
 
335
_GL_WARN_ON_USE (mkostemp, "mkostemp is unportable - "
 
336
                 "use gnulib module mkostemp for portability");
 
337
# endif
232
338
#endif
233
339
 
 
340
#if @GNULIB_MKOSTEMPS@
 
341
/* Create a unique temporary file from TEMPLATE.
 
342
   The last six characters of TEMPLATE before a suffix of length
 
343
   SUFFIXLEN must be "XXXXXX";
 
344
   they are replaced with a string that makes the file name unique.
 
345
   The flags are a bitmask, possibly including O_CLOEXEC (defined in <fcntl.h>)
 
346
   and O_TEXT, O_BINARY (defined in "binary-io.h").
 
347
   The file is then created, with the specified flags, ensuring it didn't exist
 
348
   before.
 
349
   The file is created read-write (mask at least 0600 & ~umask), but it may be
 
350
   world-readable and world-writable (mask 0666 & ~umask), depending on the
 
351
   implementation.
 
352
   Returns the open file descriptor if successful, otherwise -1 and errno
 
353
   set.  */
 
354
# if !@HAVE_MKOSTEMPS@
 
355
_GL_FUNCDECL_SYS (mkostemps, int,
 
356
                  (char * /*template*/, int /*suffixlen*/, int /*flags*/)
 
357
                  _GL_ARG_NONNULL ((1)));
 
358
# endif
 
359
_GL_CXXALIAS_SYS (mkostemps, int,
 
360
                  (char * /*template*/, int /*suffixlen*/, int /*flags*/));
 
361
_GL_CXXALIASWARN (mkostemps);
 
362
#elif defined GNULIB_POSIXCHECK
 
363
# undef mkostemps
 
364
# if HAVE_RAW_DECL_MKOSTEMPS
 
365
_GL_WARN_ON_USE (mkostemps, "mkostemps is unportable - "
 
366
                 "use gnulib module mkostemps for portability");
 
367
# endif
 
368
#endif
234
369
 
235
370
#if @GNULIB_MKSTEMP@
 
371
/* Create a unique temporary file from TEMPLATE.
 
372
   The last six characters of TEMPLATE must be "XXXXXX";
 
373
   they are replaced with a string that makes the file name unique.
 
374
   The file is then created, ensuring it didn't exist before.
 
375
   The file is created read-write (mask at least 0600 & ~umask), but it may be
 
376
   world-readable and world-writable (mask 0666 & ~umask), depending on the
 
377
   implementation.
 
378
   Returns the open file descriptor if successful, otherwise -1 and errno
 
379
   set.  */
236
380
# if @REPLACE_MKSTEMP@
237
 
/* Create a unique temporary file from TEMPLATE.
238
 
   The last six characters of TEMPLATE must be "XXXXXX";
239
 
   they are replaced with a string that makes the file name unique.
240
 
   The file is then created, ensuring it didn't exist before.
241
 
   The file is created read-write (mask at least 0600 & ~umask), but it may be
242
 
   world-readable and world-writable (mask 0666 & ~umask), depending on the
243
 
   implementation.
244
 
   Returns the open file descriptor if successful, otherwise -1 and errno
245
 
   set.  */
246
 
#  define mkstemp rpl_mkstemp
247
 
extern int mkstemp (char * /*template*/);
 
381
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
382
#   define mkstemp rpl_mkstemp
 
383
#  endif
 
384
_GL_FUNCDECL_RPL (mkstemp, int, (char * /*template*/) _GL_ARG_NONNULL ((1)));
 
385
_GL_CXXALIAS_RPL (mkstemp, int, (char * /*template*/));
248
386
# else
249
 
/* On MacOS X 10.3, only <unistd.h> declares mkstemp.  */
250
 
#  include <unistd.h>
 
387
#  if ! @HAVE_MKSTEMP@
 
388
_GL_FUNCDECL_SYS (mkstemp, int, (char * /*template*/) _GL_ARG_NONNULL ((1)));
 
389
#  endif
 
390
_GL_CXXALIAS_SYS (mkstemp, int, (char * /*template*/));
251
391
# endif
 
392
_GL_CXXALIASWARN (mkstemp);
252
393
#elif defined GNULIB_POSIXCHECK
253
394
# undef mkstemp
254
 
# define mkstemp(t) \
255
 
    (GL_LINK_WARNING ("mkstemp is unportable - " \
256
 
                      "use gnulib module mkstemp for portability"), \
257
 
     mkstemp (t))
258
 
#endif
259
 
 
 
395
# if HAVE_RAW_DECL_MKSTEMP
 
396
_GL_WARN_ON_USE (mkstemp, "mkstemp is unportable - "
 
397
                 "use gnulib module mkstemp for portability");
 
398
# endif
 
399
#endif
 
400
 
 
401
#if @GNULIB_MKSTEMPS@
 
402
/* Create a unique temporary file from TEMPLATE.
 
403
   The last six characters of TEMPLATE prior to a suffix of length
 
404
   SUFFIXLEN must be "XXXXXX";
 
405
   they are replaced with a string that makes the file name unique.
 
406
   The file is then created, ensuring it didn't exist before.
 
407
   The file is created read-write (mask at least 0600 & ~umask), but it may be
 
408
   world-readable and world-writable (mask 0666 & ~umask), depending on the
 
409
   implementation.
 
410
   Returns the open file descriptor if successful, otherwise -1 and errno
 
411
   set.  */
 
412
# if !@HAVE_MKSTEMPS@
 
413
_GL_FUNCDECL_SYS (mkstemps, int, (char * /*template*/, int /*suffixlen*/)
 
414
                                 _GL_ARG_NONNULL ((1)));
 
415
# endif
 
416
_GL_CXXALIAS_SYS (mkstemps, int, (char * /*template*/, int /*suffixlen*/));
 
417
_GL_CXXALIASWARN (mkstemps);
 
418
#elif defined GNULIB_POSIXCHECK
 
419
# undef mkstemps
 
420
# if HAVE_RAW_DECL_MKSTEMPS
 
421
_GL_WARN_ON_USE (mkstemps, "mkstemps is unportable - "
 
422
                 "use gnulib module mkstemps for portability");
 
423
# endif
 
424
#endif
 
425
 
 
426
#if @GNULIB_PTSNAME@
 
427
/* Return the pathname of the pseudo-terminal slave associated with
 
428
   the master FD is open on, or NULL on errors.  */
 
429
# if !@HAVE_PTSNAME@
 
430
_GL_FUNCDECL_SYS (ptsname, char *, (int fd));
 
431
# endif
 
432
_GL_CXXALIAS_SYS (ptsname, char *, (int fd));
 
433
_GL_CXXALIASWARN (ptsname);
 
434
#elif defined GNULIB_POSIXCHECK
 
435
# undef ptsname
 
436
# if HAVE_RAW_DECL_PTSNAME
 
437
_GL_WARN_ON_USE (ptsname, "ptsname is not portable - "
 
438
                 "use gnulib module ptsname for portability");
 
439
# endif
 
440
#endif
260
441
 
261
442
#if @GNULIB_PUTENV@
262
443
# if @REPLACE_PUTENV@
263
 
#  undef putenv
264
 
#  define putenv rpl_putenv
265
 
extern int putenv (char *string);
 
444
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
445
#   undef putenv
 
446
#   define putenv rpl_putenv
 
447
#  endif
 
448
_GL_FUNCDECL_RPL (putenv, int, (char *string) _GL_ARG_NONNULL ((1)));
 
449
_GL_CXXALIAS_RPL (putenv, int, (char *string));
 
450
# else
 
451
_GL_CXXALIAS_SYS (putenv, int, (char *string));
266
452
# endif
 
453
_GL_CXXALIASWARN (putenv);
267
454
#endif
268
455
 
269
456
 
270
457
#if @GNULIB_RANDOM_R@
271
458
# if !@HAVE_RANDOM_R@
272
 
 
273
459
#  ifndef RAND_MAX
274
460
#   define RAND_MAX 2147483647
275
461
#  endif
 
462
# endif
 
463
#endif
276
464
 
277
 
int srandom_r (unsigned int seed, struct random_data *rand_state);
278
 
int initstate_r (unsigned int seed, char *buf, size_t buf_size,
279
 
                 struct random_data *rand_state);
280
 
int setstate_r (char *arg_state, struct random_data *rand_state);
281
 
int random_r (struct random_data *buf, int32_t *result);
 
465
#if @GNULIB_RANDOM_R@
 
466
# if !@HAVE_RANDOM_R@
 
467
_GL_FUNCDECL_SYS (random_r, int, (struct random_data *buf, int32_t *result)
 
468
                                 _GL_ARG_NONNULL ((1, 2)));
282
469
# endif
 
470
_GL_CXXALIAS_SYS (random_r, int, (struct random_data *buf, int32_t *result));
 
471
_GL_CXXALIASWARN (random_r);
283
472
#elif defined GNULIB_POSIXCHECK
284
473
# undef random_r
285
 
# define random_r(b,r)                            \
286
 
    (GL_LINK_WARNING ("random_r is unportable - " \
287
 
                      "use gnulib module random_r for portability"), \
288
 
     random_r (b,r))
 
474
# if HAVE_RAW_DECL_RANDOM_R
 
475
_GL_WARN_ON_USE (random_r, "random_r is unportable - "
 
476
                 "use gnulib module random_r for portability");
 
477
# endif
 
478
#endif
 
479
 
 
480
#if @GNULIB_RANDOM_R@
 
481
# if !@HAVE_RANDOM_R@
 
482
_GL_FUNCDECL_SYS (srandom_r, int,
 
483
                  (unsigned int seed, struct random_data *rand_state)
 
484
                  _GL_ARG_NONNULL ((2)));
 
485
# endif
 
486
_GL_CXXALIAS_SYS (srandom_r, int,
 
487
                  (unsigned int seed, struct random_data *rand_state));
 
488
_GL_CXXALIASWARN (srandom_r);
 
489
#elif defined GNULIB_POSIXCHECK
 
490
# undef srandom_r
 
491
# if HAVE_RAW_DECL_SRANDOM_R
 
492
_GL_WARN_ON_USE (srandom_r, "srandom_r is unportable - "
 
493
                 "use gnulib module random_r for portability");
 
494
# endif
 
495
#endif
 
496
 
 
497
#if @GNULIB_RANDOM_R@
 
498
# if !@HAVE_RANDOM_R@
 
499
_GL_FUNCDECL_SYS (initstate_r, int,
 
500
                  (unsigned int seed, char *buf, size_t buf_size,
 
501
                   struct random_data *rand_state)
 
502
                  _GL_ARG_NONNULL ((2, 4)));
 
503
# endif
 
504
_GL_CXXALIAS_SYS (initstate_r, int,
 
505
                  (unsigned int seed, char *buf, size_t buf_size,
 
506
                   struct random_data *rand_state));
 
507
_GL_CXXALIASWARN (initstate_r);
 
508
#elif defined GNULIB_POSIXCHECK
289
509
# undef initstate_r
290
 
# define initstate_r(s,b,sz,r)                       \
291
 
    (GL_LINK_WARNING ("initstate_r is unportable - " \
292
 
                      "use gnulib module random_r for portability"), \
293
 
     initstate_r (s,b,sz,r))
294
 
# undef srandom_r
295
 
# define srandom_r(s,r)                            \
296
 
    (GL_LINK_WARNING ("srandom_r is unportable - " \
297
 
                      "use gnulib module random_r for portability"), \
298
 
     srandom_r (s,r))
 
510
# if HAVE_RAW_DECL_INITSTATE_R
 
511
_GL_WARN_ON_USE (initstate_r, "initstate_r is unportable - "
 
512
                 "use gnulib module random_r for portability");
 
513
# endif
 
514
#endif
 
515
 
 
516
#if @GNULIB_RANDOM_R@
 
517
# if !@HAVE_RANDOM_R@
 
518
_GL_FUNCDECL_SYS (setstate_r, int,
 
519
                  (char *arg_state, struct random_data *rand_state)
 
520
                  _GL_ARG_NONNULL ((1, 2)));
 
521
# endif
 
522
_GL_CXXALIAS_SYS (setstate_r, int,
 
523
                  (char *arg_state, struct random_data *rand_state));
 
524
_GL_CXXALIASWARN (setstate_r);
 
525
#elif defined GNULIB_POSIXCHECK
299
526
# undef setstate_r
300
 
# define setstate_r(a,r)                                    \
301
 
    (GL_LINK_WARNING ("setstate_r is unportable - " \
302
 
                      "use gnulib module random_r for portability"), \
303
 
     setstate_r (a,r))
304
 
#endif
305
 
 
 
527
# if HAVE_RAW_DECL_SETSTATE_R
 
528
_GL_WARN_ON_USE (setstate_r, "setstate_r is unportable - "
 
529
                 "use gnulib module random_r for portability");
 
530
# endif
 
531
#endif
 
532
 
 
533
 
 
534
#if @GNULIB_REALLOC_POSIX@
 
535
# if @REPLACE_REALLOC@
 
536
#  if !((defined __cplusplus && defined GNULIB_NAMESPACE) \
 
537
        || _GL_USE_STDLIB_ALLOC)
 
538
#   undef realloc
 
539
#   define realloc rpl_realloc
 
540
#  endif
 
541
_GL_FUNCDECL_RPL (realloc, void *, (void *ptr, size_t size));
 
542
_GL_CXXALIAS_RPL (realloc, void *, (void *ptr, size_t size));
 
543
# else
 
544
_GL_CXXALIAS_SYS (realloc, void *, (void *ptr, size_t size));
 
545
# endif
 
546
_GL_CXXALIASWARN (realloc);
 
547
#elif defined GNULIB_POSIXCHECK && !_GL_USE_STDLIB_ALLOC
 
548
# undef realloc
 
549
/* Assume realloc is always declared.  */
 
550
_GL_WARN_ON_USE (realloc, "realloc is not POSIX compliant everywhere - "
 
551
                 "use gnulib module realloc-posix for portability");
 
552
#endif
 
553
 
 
554
#if @GNULIB_REALPATH@
 
555
# if @REPLACE_REALPATH@
 
556
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
557
#   define realpath rpl_realpath
 
558
#  endif
 
559
_GL_FUNCDECL_RPL (realpath, char *, (const char *name, char *resolved)
 
560
                                    _GL_ARG_NONNULL ((1)));
 
561
_GL_CXXALIAS_RPL (realpath, char *, (const char *name, char *resolved));
 
562
# else
 
563
#  if !@HAVE_REALPATH@
 
564
_GL_FUNCDECL_SYS (realpath, char *, (const char *name, char *resolved)
 
565
                                    _GL_ARG_NONNULL ((1)));
 
566
#  endif
 
567
_GL_CXXALIAS_SYS (realpath, char *, (const char *name, char *resolved));
 
568
# endif
 
569
_GL_CXXALIASWARN (realpath);
 
570
#elif defined GNULIB_POSIXCHECK
 
571
# undef realpath
 
572
# if HAVE_RAW_DECL_REALPATH
 
573
_GL_WARN_ON_USE (realpath, "realpath is unportable - use gnulib module "
 
574
                 "canonicalize or canonicalize-lgpl for portability");
 
575
# endif
 
576
#endif
306
577
 
307
578
#if @GNULIB_RPMATCH@
308
 
# if !@HAVE_RPMATCH@
309
579
/* Test a user response to a question.
310
580
   Return 1 if it is affirmative, 0 if it is negative, or -1 if not clear.  */
311
 
extern int rpmatch (const char *response);
 
581
# if !@HAVE_RPMATCH@
 
582
_GL_FUNCDECL_SYS (rpmatch, int, (const char *response) _GL_ARG_NONNULL ((1)));
312
583
# endif
 
584
_GL_CXXALIAS_SYS (rpmatch, int, (const char *response));
 
585
_GL_CXXALIASWARN (rpmatch);
313
586
#elif defined GNULIB_POSIXCHECK
314
587
# undef rpmatch
315
 
# define rpmatch(r) \
316
 
    (GL_LINK_WARNING ("rpmatch is unportable - " \
317
 
                      "use gnulib module rpmatch for portability"), \
318
 
     rpmatch (r))
 
588
# if HAVE_RAW_DECL_RPMATCH
 
589
_GL_WARN_ON_USE (rpmatch, "rpmatch is unportable - "
 
590
                 "use gnulib module rpmatch for portability");
 
591
# endif
319
592
#endif
320
593
 
321
 
 
322
594
#if @GNULIB_SETENV@
323
 
# if !@HAVE_SETENV@
324
595
/* Set NAME to VALUE in the environment.
325
596
   If REPLACE is nonzero, overwrite an existing value.  */
326
 
extern int setenv (const char *name, const char *value, int replace);
327
 
# endif
328
 
#endif
329
 
 
330
 
 
331
 
#if @GNULIB_UNSETENV@
332
 
# if @HAVE_UNSETENV@
333
 
#  if @VOID_UNSETENV@
334
 
/* On some systems, unsetenv() returns void.
335
 
   This is the case for MacOS X 10.3, FreeBSD 4.8, NetBSD 1.6, OpenBSD 3.4.  */
336
 
#   define unsetenv(name) ((unsetenv)(name), 0)
 
597
# if @REPLACE_SETENV@
 
598
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
599
#   undef setenv
 
600
#   define setenv rpl_setenv
337
601
#  endif
 
602
_GL_FUNCDECL_RPL (setenv, int,
 
603
                  (const char *name, const char *value, int replace)
 
604
                  _GL_ARG_NONNULL ((1)));
 
605
_GL_CXXALIAS_RPL (setenv, int,
 
606
                  (const char *name, const char *value, int replace));
338
607
# else
339
 
/* Remove the variable NAME from the environment.  */
340
 
extern int unsetenv (const char *name);
 
608
#  if !@HAVE_DECL_SETENV@
 
609
_GL_FUNCDECL_SYS (setenv, int,
 
610
                  (const char *name, const char *value, int replace)
 
611
                  _GL_ARG_NONNULL ((1)));
 
612
#  endif
 
613
_GL_CXXALIAS_SYS (setenv, int,
 
614
                  (const char *name, const char *value, int replace));
 
615
# endif
 
616
# if !(@REPLACE_SETENV@ && !@HAVE_DECL_SETENV@)
 
617
_GL_CXXALIASWARN (setenv);
 
618
# endif
 
619
#elif defined GNULIB_POSIXCHECK
 
620
# undef setenv
 
621
# if HAVE_RAW_DECL_SETENV
 
622
_GL_WARN_ON_USE (setenv, "setenv is unportable - "
 
623
                 "use gnulib module setenv for portability");
341
624
# endif
342
625
#endif
343
626
 
344
 
 
345
627
#if @GNULIB_STRTOD@
 
628
 /* Parse a double from STRING, updating ENDP if appropriate.  */
346
629
# if @REPLACE_STRTOD@
347
 
#  define strtod rpl_strtod
348
 
# endif
349
 
# if !@HAVE_STRTOD@ || @REPLACE_STRTOD@
350
 
 /* Parse a double from STRING, updating ENDP if appropriate.  */
351
 
extern double strtod (const char *str, char **endp);
352
 
# endif
 
630
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
631
#   define strtod rpl_strtod
 
632
#  endif
 
633
_GL_FUNCDECL_RPL (strtod, double, (const char *str, char **endp)
 
634
                                  _GL_ARG_NONNULL ((1)));
 
635
_GL_CXXALIAS_RPL (strtod, double, (const char *str, char **endp));
 
636
# else
 
637
#  if !@HAVE_STRTOD@
 
638
_GL_FUNCDECL_SYS (strtod, double, (const char *str, char **endp)
 
639
                                  _GL_ARG_NONNULL ((1)));
 
640
#  endif
 
641
_GL_CXXALIAS_SYS (strtod, double, (const char *str, char **endp));
 
642
# endif
 
643
_GL_CXXALIASWARN (strtod);
353
644
#elif defined GNULIB_POSIXCHECK
354
645
# undef strtod
355
 
# define strtod(s, e)                           \
356
 
    (GL_LINK_WARNING ("strtod is unportable - " \
357
 
                      "use gnulib module strtod for portability"), \
358
 
     strtod (s, e))
 
646
# if HAVE_RAW_DECL_STRTOD
 
647
_GL_WARN_ON_USE (strtod, "strtod is unportable - "
 
648
                 "use gnulib module strtod for portability");
 
649
# endif
359
650
#endif
360
651
 
361
 
 
362
652
#if @GNULIB_STRTOLL@
363
 
# if !@HAVE_STRTOLL@
364
653
/* Parse a signed integer whose textual representation starts at STRING.
365
654
   The integer is expected to be in base BASE (2 <= BASE <= 36); if BASE == 0,
366
655
   it may be decimal or octal (with prefix "0") or hexadecimal (with prefix
369
658
   stored in *ENDPTR.
370
659
   Upon overflow, the return value is LLONG_MAX or LLONG_MIN, and errno is set
371
660
   to ERANGE.  */
372
 
extern long long strtoll (const char *string, char **endptr, int base);
 
661
# if !@HAVE_STRTOLL@
 
662
_GL_FUNCDECL_SYS (strtoll, long long,
 
663
                  (const char *string, char **endptr, int base)
 
664
                  _GL_ARG_NONNULL ((1)));
373
665
# endif
 
666
_GL_CXXALIAS_SYS (strtoll, long long,
 
667
                  (const char *string, char **endptr, int base));
 
668
_GL_CXXALIASWARN (strtoll);
374
669
#elif defined GNULIB_POSIXCHECK
375
670
# undef strtoll
376
 
# define strtoll(s,e,b) \
377
 
    (GL_LINK_WARNING ("strtoll is unportable - " \
378
 
                      "use gnulib module strtoll for portability"), \
379
 
     strtoll (s, e, b))
 
671
# if HAVE_RAW_DECL_STRTOLL
 
672
_GL_WARN_ON_USE (strtoll, "strtoll is unportable - "
 
673
                 "use gnulib module strtoll for portability");
 
674
# endif
380
675
#endif
381
676
 
382
 
 
383
677
#if @GNULIB_STRTOULL@
384
 
# if !@HAVE_STRTOULL@
385
678
/* Parse an unsigned integer whose textual representation starts at STRING.
386
679
   The integer is expected to be in base BASE (2 <= BASE <= 36); if BASE == 0,
387
680
   it may be decimal or octal (with prefix "0") or hexadecimal (with prefix
390
683
   stored in *ENDPTR.
391
684
   Upon overflow, the return value is ULLONG_MAX, and errno is set to
392
685
   ERANGE.  */
393
 
extern unsigned long long strtoull (const char *string, char **endptr, int base);
 
686
# if !@HAVE_STRTOULL@
 
687
_GL_FUNCDECL_SYS (strtoull, unsigned long long,
 
688
                  (const char *string, char **endptr, int base)
 
689
                  _GL_ARG_NONNULL ((1)));
394
690
# endif
 
691
_GL_CXXALIAS_SYS (strtoull, unsigned long long,
 
692
                  (const char *string, char **endptr, int base));
 
693
_GL_CXXALIASWARN (strtoull);
395
694
#elif defined GNULIB_POSIXCHECK
396
695
# undef strtoull
397
 
# define strtoull(s,e,b) \
398
 
    (GL_LINK_WARNING ("strtoull is unportable - " \
399
 
                      "use gnulib module strtoull for portability"), \
400
 
     strtoull (s, e, b))
401
 
#endif
402
 
 
403
 
 
404
 
#ifdef __cplusplus
405
 
}
406
 
#endif
407
 
 
408
 
#endif /* _GL_STDLIB_H */
409
 
#endif /* _GL_STDLIB_H */
 
696
# if HAVE_RAW_DECL_STRTOULL
 
697
_GL_WARN_ON_USE (strtoull, "strtoull is unportable - "
 
698
                 "use gnulib module strtoull for portability");
 
699
# endif
 
700
#endif
 
701
 
 
702
#if @GNULIB_UNLOCKPT@
 
703
/* Unlock the slave side of the pseudo-terminal whose master side is specified
 
704
   by FD, so that it can be opened.  */
 
705
# if !@HAVE_UNLOCKPT@
 
706
_GL_FUNCDECL_SYS (unlockpt, int, (int fd));
 
707
# endif
 
708
_GL_CXXALIAS_SYS (unlockpt, int, (int fd));
 
709
_GL_CXXALIASWARN (unlockpt);
 
710
#elif defined GNULIB_POSIXCHECK
 
711
# undef unlockpt
 
712
# if HAVE_RAW_DECL_UNLOCKPT
 
713
_GL_WARN_ON_USE (unlockpt, "unlockpt is not portable - "
 
714
                 "use gnulib module unlockpt for portability");
 
715
# endif
 
716
#endif
 
717
 
 
718
#if @GNULIB_UNSETENV@
 
719
/* Remove the variable NAME from the environment.  */
 
720
# if @REPLACE_UNSETENV@
 
721
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
722
#   undef unsetenv
 
723
#   define unsetenv rpl_unsetenv
 
724
#  endif
 
725
_GL_FUNCDECL_RPL (unsetenv, int, (const char *name) _GL_ARG_NONNULL ((1)));
 
726
_GL_CXXALIAS_RPL (unsetenv, int, (const char *name));
 
727
# else
 
728
#  if !@HAVE_DECL_UNSETENV@
 
729
_GL_FUNCDECL_SYS (unsetenv, int, (const char *name) _GL_ARG_NONNULL ((1)));
 
730
#  endif
 
731
_GL_CXXALIAS_SYS (unsetenv, int, (const char *name));
 
732
# endif
 
733
# if !(@REPLACE_UNSETENV@ && !@HAVE_DECL_UNSETENV@)
 
734
_GL_CXXALIASWARN (unsetenv);
 
735
# endif
 
736
#elif defined GNULIB_POSIXCHECK
 
737
# undef unsetenv
 
738
# if HAVE_RAW_DECL_UNSETENV
 
739
_GL_WARN_ON_USE (unsetenv, "unsetenv is unportable - "
 
740
                 "use gnulib module unsetenv for portability");
 
741
# endif
 
742
#endif
 
743
 
 
744
/* Convert a wide character to a multibyte character.  */
 
745
#if @GNULIB_WCTOMB@
 
746
# if @REPLACE_WCTOMB@
 
747
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
748
#   undef wctomb
 
749
#   define wctomb rpl_wctomb
 
750
#  endif
 
751
_GL_FUNCDECL_RPL (wctomb, int, (char *s, wchar_t wc));
 
752
_GL_CXXALIAS_RPL (wctomb, int, (char *s, wchar_t wc));
 
753
# else
 
754
_GL_CXXALIAS_SYS (wctomb, int, (char *s, wchar_t wc));
 
755
# endif
 
756
_GL_CXXALIASWARN (wctomb);
 
757
#endif
 
758
 
 
759
 
 
760
#endif /* _@GUARD_PREFIX@_STDLIB_H */
 
761
#endif /* _@GUARD_PREFIX@_STDLIB_H */
410
762
#endif