1 /* -*- buffer-read-only: t -*- vi: set ro: */
2 /* DO NOT EDIT! GENERATED AUTOMATICALLY! */
3 /* A GNU-like <stdlib.h>.
5 Copyright (C) 1995, 2001-2004, 2006-2010 Free Software Foundation, Inc.
7 This program is free software: you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 3 of the License, or
10 (at your option) any later version.
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with this program. If not, see <http://www.gnu.org/licenses/>. */
21 @PRAGMA_SYSTEM_HEADER@
24 #if defined __need_malloc_and_calloc
25 /* Special invocation convention inside glibc header files. */
27 #@INCLUDE_NEXT@ @NEXT_STDLIB_H@
30 /* Normal invocation convention. */
34 /* The include_next requires a split double-inclusion guard. */
35 #@INCLUDE_NEXT@ @NEXT_STDLIB_H@
40 /* NetBSD 5.0 mis-defines NULL. */
43 /* Solaris declares getloadavg() in <sys/loadavg.h>. */
44 #if (@GNULIB_GETLOADAVG@ || defined GNULIB_POSIXCHECK) && @HAVE_SYS_LOADAVG_H@
45 # include <sys/loadavg.h>
48 /* OSF/1 5.1 declares 'struct random_data' in <random.h>, which is included
49 from <stdlib.h> if _REENTRANT is defined. Include it always. */
54 #if !@HAVE_STRUCT_RANDOM_DATA@ || (@GNULIB_RANDOM_R@ && !@HAVE_RANDOM_R@) \
55 || defined GNULIB_POSIXCHECK
59 #if !@HAVE_STRUCT_RANDOM_DATA@
62 int32_t *fptr; /* Front pointer. */
63 int32_t *rptr; /* Rear pointer. */
64 int32_t *state; /* Array of state values. */
65 int rand_type; /* Type of random number generator. */
66 int rand_deg; /* Degree of random number generator. */
67 int rand_sep; /* Distance between front and rear. */
68 int32_t *end_ptr; /* Pointer behind state table. */
72 #if (@GNULIB_MKSTEMP@ || @GNULIB_GETSUBOPT@ || defined GNULIB_POSIXCHECK) && ! defined __GLIBC__
73 /* On MacOS X 10.3, only <unistd.h> declares mkstemp. */
74 /* On Cygwin 1.7.1, only <unistd.h> declares getsubopt. */
75 /* But avoid namespace pollution on glibc systems. */
79 /* The definitions of _GL_FUNCDECL_RPL etc. are copied here. */
81 /* The definition of _GL_ARG_NONNULL is copied here. */
83 /* The definition of _GL_WARN_ON_USE is copied here. */
86 /* Some systems do not define EXIT_*, despite otherwise supporting C89. */
88 # define EXIT_SUCCESS 0
90 /* Tandem/NSK and other platforms that define EXIT_FAILURE as -1 interfere
91 with proper operation of xargs. */
93 # define EXIT_FAILURE 1
94 #elif EXIT_FAILURE != 1
96 # define EXIT_FAILURE 1
101 /* Parse a signed decimal integer.
102 Returns the value of the integer. Errors are not detected. */
104 _GL_FUNCDECL_SYS (atoll, long long, (const char *string) _GL_ARG_NONNULL ((1)));
106 _GL_CXXALIAS_SYS (atoll, long long, (const char *string));
107 _GL_CXXALIASWARN (atoll);
108 #elif defined GNULIB_POSIXCHECK
110 # if HAVE_RAW_DECL_ATOLL
111 _GL_WARN_ON_USE (atoll, "atoll is unportable - "
112 "use gnulib module atoll for portability");
116 #if @GNULIB_CALLOC_POSIX@
117 # if !@HAVE_CALLOC_POSIX@
118 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
120 # define calloc rpl_calloc
122 _GL_FUNCDECL_RPL (calloc, void *, (size_t nmemb, size_t size));
123 _GL_CXXALIAS_RPL (calloc, void *, (size_t nmemb, size_t size));
125 _GL_CXXALIAS_SYS (calloc, void *, (size_t nmemb, size_t size));
127 _GL_CXXALIASWARN (calloc);
128 #elif defined GNULIB_POSIXCHECK
130 /* Assume calloc is always declared. */
131 _GL_WARN_ON_USE (calloc, "calloc is not POSIX compliant everywhere - "
132 "use gnulib module calloc-posix for portability");
135 #if @GNULIB_CANONICALIZE_FILE_NAME@
136 # if @REPLACE_CANONICALIZE_FILE_NAME@
137 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
138 # define canonicalize_file_name rpl_canonicalize_file_name
140 _GL_FUNCDECL_RPL (canonicalize_file_name, char *, (const char *name)
141 _GL_ARG_NONNULL ((1)));
142 _GL_CXXALIAS_RPL (canonicalize_file_name, char *, (const char *name));
144 # if !@HAVE_CANONICALIZE_FILE_NAME@
145 _GL_FUNCDECL_SYS (canonicalize_file_name, char *, (const char *name)
146 _GL_ARG_NONNULL ((1)));
148 _GL_CXXALIAS_SYS (canonicalize_file_name, char *, (const char *name));
150 _GL_CXXALIASWARN (canonicalize_file_name);
151 #elif defined GNULIB_POSIXCHECK
152 # undef canonicalize_file_name
153 # if HAVE_RAW_DECL_CANONICALIZE_FILE_NAME
154 _GL_WARN_ON_USE (canonicalize_file_name, "canonicalize_file_name is unportable - "
155 "use gnulib module canonicalize-lgpl for portability");
159 #if @GNULIB_GETLOADAVG@
160 /* Store max(NELEM,3) load average numbers in LOADAVG[].
161 The three numbers are the load average of the last 1 minute, the last 5
162 minutes, and the last 15 minutes, respectively.
163 LOADAVG is an array of NELEM numbers. */
164 # if !@HAVE_DECL_GETLOADAVG@
165 _GL_FUNCDECL_SYS (getloadavg, int, (double loadavg[], int nelem)
166 _GL_ARG_NONNULL ((1)));
168 _GL_CXXALIAS_SYS (getloadavg, int, (double loadavg[], int nelem));
169 _GL_CXXALIASWARN (getloadavg);
170 #elif defined GNULIB_POSIXCHECK
172 # if HAVE_RAW_DECL_GETLOADAVG
173 _GL_WARN_ON_USE (getloadavg, "getloadavg is not portable - "
174 "use gnulib module getloadavg for portability");
178 #if @GNULIB_GETSUBOPT@
179 /* Assuming *OPTIONP is a comma separated list of elements of the form
180 "token" or "token=value", getsubopt parses the first of these elements.
181 If the first element refers to a "token" that is member of the given
182 NULL-terminated array of tokens:
183 - It replaces the comma with a NUL byte, updates *OPTIONP to point past
184 the first option and the comma, sets *VALUEP to the value of the
185 element (or NULL if it doesn't contain an "=" sign),
186 - It returns the index of the "token" in the given array of tokens.
187 Otherwise it returns -1, and *OPTIONP and *VALUEP are undefined.
188 For more details see the POSIX:2001 specification.
189 http://www.opengroup.org/susv3xsh/getsubopt.html */
190 # if !@HAVE_GETSUBOPT@
191 _GL_FUNCDECL_SYS (getsubopt, int,
192 (char **optionp, char *const *tokens, char **valuep)
193 _GL_ARG_NONNULL ((1, 2, 3)));
195 _GL_CXXALIAS_SYS (getsubopt, int,
196 (char **optionp, char *const *tokens, char **valuep));
197 _GL_CXXALIASWARN (getsubopt);
198 #elif defined GNULIB_POSIXCHECK
200 # if HAVE_RAW_DECL_GETSUBOPT
201 _GL_WARN_ON_USE (getsubopt, "getsubopt is unportable - "
202 "use gnulib module getsubopt for portability");
206 #if @GNULIB_MALLOC_POSIX@
207 # if !@HAVE_MALLOC_POSIX@
208 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
210 # define malloc rpl_malloc
212 _GL_FUNCDECL_RPL (malloc, void *, (size_t size));
213 _GL_CXXALIAS_RPL (malloc, void *, (size_t size));
215 _GL_CXXALIAS_SYS (malloc, void *, (size_t size));
217 _GL_CXXALIASWARN (malloc);
218 #elif defined GNULIB_POSIXCHECK
220 /* Assume malloc is always declared. */
221 _GL_WARN_ON_USE (malloc, "malloc is not POSIX compliant everywhere - "
222 "use gnulib module malloc-posix for portability");
226 /* Create a unique temporary directory from TEMPLATE.
227 The last six characters of TEMPLATE must be "XXXXXX";
228 they are replaced with a string that makes the directory name unique.
229 Returns TEMPLATE, or a null pointer if it cannot get a unique name.
230 The directory is created mode 700. */
232 _GL_FUNCDECL_SYS (mkdtemp, char *, (char * /*template*/) _GL_ARG_NONNULL ((1)));
234 _GL_CXXALIAS_SYS (mkdtemp, char *, (char * /*template*/));
235 _GL_CXXALIASWARN (mkdtemp);
236 #elif defined GNULIB_POSIXCHECK
238 # if HAVE_RAW_DECL_MKDTEMP
239 _GL_WARN_ON_USE (mkdtemp, "mkdtemp is unportable - "
240 "use gnulib module mkdtemp for portability");
244 #if @GNULIB_MKOSTEMP@
245 /* Create a unique temporary file from TEMPLATE.
246 The last six characters of TEMPLATE must be "XXXXXX";
247 they are replaced with a string that makes the file name unique.
248 The flags are a bitmask, possibly including O_CLOEXEC (defined in <fcntl.h>)
249 and O_TEXT, O_BINARY (defined in "binary-io.h").
250 The file is then created, with the specified flags, ensuring it didn't exist
252 The file is created read-write (mask at least 0600 & ~umask), but it may be
253 world-readable and world-writable (mask 0666 & ~umask), depending on the
255 Returns the open file descriptor if successful, otherwise -1 and errno
257 # if !@HAVE_MKOSTEMP@
258 _GL_FUNCDECL_SYS (mkostemp, int, (char * /*template*/, int /*flags*/)
259 _GL_ARG_NONNULL ((1)));
261 _GL_CXXALIAS_SYS (mkostemp, int, (char * /*template*/, int /*flags*/));
262 _GL_CXXALIASWARN (mkostemp);
263 #elif defined GNULIB_POSIXCHECK
265 # if HAVE_RAW_DECL_MKOSTEMP
266 _GL_WARN_ON_USE (mkostemp, "mkostemp is unportable - "
267 "use gnulib module mkostemp for portability");
271 #if @GNULIB_MKOSTEMPS@
272 /* Create a unique temporary file from TEMPLATE.
273 The last six characters of TEMPLATE before a suffix of length
274 SUFFIXLEN must be "XXXXXX";
275 they are replaced with a string that makes the file name unique.
276 The flags are a bitmask, possibly including O_CLOEXEC (defined in <fcntl.h>)
277 and O_TEXT, O_BINARY (defined in "binary-io.h").
278 The file is then created, with the specified flags, ensuring it didn't exist
280 The file is created read-write (mask at least 0600 & ~umask), but it may be
281 world-readable and world-writable (mask 0666 & ~umask), depending on the
283 Returns the open file descriptor if successful, otherwise -1 and errno
285 # if !@HAVE_MKOSTEMPS@
286 _GL_FUNCDECL_SYS (mkostemps, int,
287 (char * /*template*/, int /*suffixlen*/, int /*flags*/)
288 _GL_ARG_NONNULL ((1)));
290 _GL_CXXALIAS_SYS (mkostemps, int,
291 (char * /*template*/, int /*suffixlen*/, int /*flags*/));
292 _GL_CXXALIASWARN (mkostemps);
293 #elif defined GNULIB_POSIXCHECK
295 # if HAVE_RAW_DECL_MKOSTEMPS
296 _GL_WARN_ON_USE (mkostemps, "mkostemps is unportable - "
297 "use gnulib module mkostemps for portability");
302 /* Create a unique temporary file from TEMPLATE.
303 The last six characters of TEMPLATE must be "XXXXXX";
304 they are replaced with a string that makes the file name unique.
305 The file is then created, ensuring it didn't exist before.
306 The file is created read-write (mask at least 0600 & ~umask), but it may be
307 world-readable and world-writable (mask 0666 & ~umask), depending on the
309 Returns the open file descriptor if successful, otherwise -1 and errno
311 # if @REPLACE_MKSTEMP@
312 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
313 # define mkstemp rpl_mkstemp
315 _GL_FUNCDECL_RPL (mkstemp, int, (char * /*template*/) _GL_ARG_NONNULL ((1)));
316 _GL_CXXALIAS_RPL (mkstemp, int, (char * /*template*/));
318 _GL_CXXALIAS_SYS (mkstemp, int, (char * /*template*/));
320 _GL_CXXALIASWARN (mkstemp);
321 #elif defined GNULIB_POSIXCHECK
323 # if HAVE_RAW_DECL_MKSTEMP
324 _GL_WARN_ON_USE (mkstemp, "mkstemp is unportable - "
325 "use gnulib module mkstemp for portability");
329 #if @GNULIB_MKSTEMPS@
330 /* Create a unique temporary file from TEMPLATE.
331 The last six characters of TEMPLATE prior to a suffix of length
332 SUFFIXLEN must be "XXXXXX";
333 they are replaced with a string that makes the file name unique.
334 The file is then created, ensuring it didn't exist before.
335 The file is created read-write (mask at least 0600 & ~umask), but it may be
336 world-readable and world-writable (mask 0666 & ~umask), depending on the
338 Returns the open file descriptor if successful, otherwise -1 and errno
340 # if !@HAVE_MKSTEMPS@
341 _GL_FUNCDECL_SYS (mkstemps, int, (char * /*template*/, int /*suffixlen*/)
342 _GL_ARG_NONNULL ((1)));
344 _GL_CXXALIAS_SYS (mkstemps, int, (char * /*template*/, int /*suffixlen*/));
345 _GL_CXXALIASWARN (mkstemps);
346 #elif defined GNULIB_POSIXCHECK
348 # if HAVE_RAW_DECL_MKSTEMPS
349 _GL_WARN_ON_USE (mkstemps, "mkstemps is unportable - "
350 "use gnulib module mkstemps for portability");
355 # if @REPLACE_PUTENV@
356 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
358 # define putenv rpl_putenv
360 _GL_FUNCDECL_RPL (putenv, int, (char *string) _GL_ARG_NONNULL ((1)));
361 _GL_CXXALIAS_RPL (putenv, int, (char *string));
363 _GL_CXXALIAS_SYS (putenv, int, (char *string));
365 _GL_CXXALIASWARN (putenv);
369 #if @GNULIB_RANDOM_R@
370 # if !@HAVE_RANDOM_R@
372 # define RAND_MAX 2147483647
377 #if @GNULIB_RANDOM_R@
378 # if !@HAVE_RANDOM_R@
379 _GL_FUNCDECL_SYS (random_r, int, (struct random_data *buf, int32_t *result)
380 _GL_ARG_NONNULL ((1, 2)));
382 _GL_CXXALIAS_SYS (random_r, int, (struct random_data *buf, int32_t *result));
383 _GL_CXXALIASWARN (random_r);
384 #elif defined GNULIB_POSIXCHECK
386 # if HAVE_RAW_DECL_RANDOM_R
387 _GL_WARN_ON_USE (random_r, "random_r is unportable - "
388 "use gnulib module random_r for portability");
392 #if @GNULIB_RANDOM_R@
393 # if !@HAVE_RANDOM_R@
394 _GL_FUNCDECL_SYS (srandom_r, int,
395 (unsigned int seed, struct random_data *rand_state)
396 _GL_ARG_NONNULL ((2)));
398 _GL_CXXALIAS_SYS (srandom_r, int,
399 (unsigned int seed, struct random_data *rand_state));
400 _GL_CXXALIASWARN (srandom_r);
401 #elif defined GNULIB_POSIXCHECK
403 # if HAVE_RAW_DECL_SRANDOM_R
404 _GL_WARN_ON_USE (srandom_r, "srandom_r is unportable - "
405 "use gnulib module random_r for portability");
409 #if @GNULIB_RANDOM_R@
410 # if !@HAVE_RANDOM_R@
411 _GL_FUNCDECL_SYS (initstate_r, int,
412 (unsigned int seed, char *buf, size_t buf_size,
413 struct random_data *rand_state)
414 _GL_ARG_NONNULL ((2, 4)));
416 _GL_CXXALIAS_SYS (initstate_r, int,
417 (unsigned int seed, char *buf, size_t buf_size,
418 struct random_data *rand_state));
419 _GL_CXXALIASWARN (initstate_r);
420 #elif defined GNULIB_POSIXCHECK
422 # if HAVE_RAW_DECL_INITSTATE_R
423 _GL_WARN_ON_USE (initstate_r, "initstate_r is unportable - "
424 "use gnulib module random_r for portability");
428 #if @GNULIB_RANDOM_R@
429 # if !@HAVE_RANDOM_R@
430 _GL_FUNCDECL_SYS (setstate_r, int,
431 (char *arg_state, struct random_data *rand_state)
432 _GL_ARG_NONNULL ((1, 2)));
434 _GL_CXXALIAS_SYS (setstate_r, int,
435 (char *arg_state, struct random_data *rand_state));
436 _GL_CXXALIASWARN (setstate_r);
437 #elif defined GNULIB_POSIXCHECK
439 # if HAVE_RAW_DECL_SETSTATE_R
440 _GL_WARN_ON_USE (setstate_r, "setstate_r is unportable - "
441 "use gnulib module random_r for portability");
446 #if @GNULIB_REALLOC_POSIX@
447 # if !@HAVE_REALLOC_POSIX@
448 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
450 # define realloc rpl_realloc
452 _GL_FUNCDECL_RPL (realloc, void *, (void *ptr, size_t size));
453 _GL_CXXALIAS_RPL (realloc, void *, (void *ptr, size_t size));
455 _GL_CXXALIAS_SYS (realloc, void *, (void *ptr, size_t size));
457 _GL_CXXALIASWARN (realloc);
458 #elif defined GNULIB_POSIXCHECK
460 /* Assume realloc is always declared. */
461 _GL_WARN_ON_USE (realloc, "realloc is not POSIX compliant everywhere - "
462 "use gnulib module realloc-posix for portability");
465 #if @GNULIB_REALPATH@
466 # if @REPLACE_REALPATH@
467 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
468 # define realpath rpl_realpath
470 _GL_FUNCDECL_RPL (realpath, char *, (const char *name, char *resolved)
471 _GL_ARG_NONNULL ((1)));
472 _GL_CXXALIAS_RPL (realpath, char *, (const char *name, char *resolved));
474 # if !@HAVE_REALPATH@
475 _GL_FUNCDECL_SYS (realpath, char *, (const char *name, char *resolved)
476 _GL_ARG_NONNULL ((1)));
478 _GL_CXXALIAS_SYS (realpath, char *, (const char *name, char *resolved));
480 _GL_CXXALIASWARN (realpath);
481 #elif defined GNULIB_POSIXCHECK
483 # if HAVE_RAW_DECL_REALPATH
484 _GL_WARN_ON_USE (realpath, "realpath is unportable - use gnulib module "
485 "canonicalize or canonicalize-lgpl for portability");
490 /* Test a user response to a question.
491 Return 1 if it is affirmative, 0 if it is negative, or -1 if not clear. */
493 _GL_FUNCDECL_SYS (rpmatch, int, (const char *response) _GL_ARG_NONNULL ((1)));
495 _GL_CXXALIAS_SYS (rpmatch, int, (const char *response));
496 _GL_CXXALIASWARN (rpmatch);
497 #elif defined GNULIB_POSIXCHECK
499 # if HAVE_RAW_DECL_RPMATCH
500 _GL_WARN_ON_USE (rpmatch, "rpmatch is unportable - "
501 "use gnulib module rpmatch for portability");
506 /* Set NAME to VALUE in the environment.
507 If REPLACE is nonzero, overwrite an existing value. */
508 # if @REPLACE_SETENV@
509 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
511 # define setenv rpl_setenv
513 _GL_FUNCDECL_RPL (setenv, int,
514 (const char *name, const char *value, int replace)
515 _GL_ARG_NONNULL ((1)));
516 _GL_CXXALIAS_RPL (setenv, int,
517 (const char *name, const char *value, int replace));
520 _GL_FUNCDECL_SYS (setenv, int,
521 (const char *name, const char *value, int replace)
522 _GL_ARG_NONNULL ((1)));
524 _GL_CXXALIAS_SYS (setenv, int,
525 (const char *name, const char *value, int replace));
527 _GL_CXXALIASWARN (setenv);
528 #elif defined GNULIB_POSIXCHECK
530 # if HAVE_RAW_DECL_SETENV
531 _GL_WARN_ON_USE (setenv, "setenv is unportable - "
532 "use gnulib module setenv for portability");
537 /* Parse a double from STRING, updating ENDP if appropriate. */
538 # if @REPLACE_STRTOD@
539 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
540 # define strtod rpl_strtod
542 _GL_FUNCDECL_RPL (strtod, double, (const char *str, char **endp)
543 _GL_ARG_NONNULL ((1)));
544 _GL_CXXALIAS_RPL (strtod, double, (const char *str, char **endp));
547 _GL_FUNCDECL_SYS (strtod, double, (const char *str, char **endp)
548 _GL_ARG_NONNULL ((1)));
550 _GL_CXXALIAS_SYS (strtod, double, (const char *str, char **endp));
552 _GL_CXXALIASWARN (strtod);
553 #elif defined GNULIB_POSIXCHECK
555 # if HAVE_RAW_DECL_STRTOD
556 _GL_WARN_ON_USE (strtod, "strtod is unportable - "
557 "use gnulib module strtod for portability");
562 /* Parse a signed integer whose textual representation starts at STRING.
563 The integer is expected to be in base BASE (2 <= BASE <= 36); if BASE == 0,
564 it may be decimal or octal (with prefix "0") or hexadecimal (with prefix
566 If ENDPTR is not NULL, the address of the first byte after the integer is
568 Upon overflow, the return value is LLONG_MAX or LLONG_MIN, and errno is set
571 _GL_FUNCDECL_SYS (strtoll, long long,
572 (const char *string, char **endptr, int base)
573 _GL_ARG_NONNULL ((1)));
575 _GL_CXXALIAS_SYS (strtoll, long long,
576 (const char *string, char **endptr, int base));
577 _GL_CXXALIASWARN (strtoll);
578 #elif defined GNULIB_POSIXCHECK
580 # if HAVE_RAW_DECL_STRTOLL
581 _GL_WARN_ON_USE (strtoll, "strtoll is unportable - "
582 "use gnulib module strtoll for portability");
586 #if @GNULIB_STRTOULL@
587 /* Parse an unsigned integer whose textual representation starts at STRING.
588 The integer is expected to be in base BASE (2 <= BASE <= 36); if BASE == 0,
589 it may be decimal or octal (with prefix "0") or hexadecimal (with prefix
591 If ENDPTR is not NULL, the address of the first byte after the integer is
593 Upon overflow, the return value is ULLONG_MAX, and errno is set to
595 # if !@HAVE_STRTOULL@
596 _GL_FUNCDECL_SYS (strtoull, unsigned long long,
597 (const char *string, char **endptr, int base)
598 _GL_ARG_NONNULL ((1)));
600 _GL_CXXALIAS_SYS (strtoull, unsigned long long,
601 (const char *string, char **endptr, int base));
602 _GL_CXXALIASWARN (strtoull);
603 #elif defined GNULIB_POSIXCHECK
605 # if HAVE_RAW_DECL_STRTOULL
606 _GL_WARN_ON_USE (strtoull, "strtoull is unportable - "
607 "use gnulib module strtoull for portability");
611 #if @GNULIB_UNSETENV@
612 /* Remove the variable NAME from the environment. */
613 # if @REPLACE_UNSETENV@
614 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
616 # define unsetenv rpl_unsetenv
618 _GL_FUNCDECL_RPL (unsetenv, int, (const char *name) _GL_ARG_NONNULL ((1)));
619 _GL_CXXALIAS_RPL (unsetenv, int, (const char *name));
621 # if !@HAVE_UNSETENV@
622 _GL_FUNCDECL_SYS (unsetenv, int, (const char *name) _GL_ARG_NONNULL ((1)));
624 _GL_CXXALIAS_SYS (unsetenv, int, (const char *name));
626 _GL_CXXALIASWARN (unsetenv);
627 #elif defined GNULIB_POSIXCHECK
629 # if HAVE_RAW_DECL_UNSETENV
630 _GL_WARN_ON_USE (unsetenv, "unsetenv is unportable - "
631 "use gnulib module unsetenv for portability");
636 #endif /* _GL_STDLIB_H */
637 #endif /* _GL_STDLIB_H */