diff options
| author | Paul Eggert | 2017-03-23 08:51:44 -0700 |
|---|---|---|
| committer | Paul Eggert | 2017-03-23 08:53:21 -0700 |
| commit | e6d3eaa69871d800eb078580b64f2bc5806a0fcc (patch) | |
| tree | 8bfe6653b6be56f06adee8e0cfbf2b366b8ac8a6 /lib/getopt.in.h | |
| parent | e1392faae5c5cc7805b52efacbb25a71213afdeb (diff) | |
| download | emacs-e6d3eaa69871d800eb078580b64f2bc5806a0fcc.tar.gz emacs-e6d3eaa69871d800eb078580b64f2bc5806a0fcc.zip | |
Merge from gnulib
This incorporates:
2017-03-22 getopt: merge from glibc
* build-aux/config.sub, lib/getopt.c, lib/getopt.in.h:
* lib/getopt1.c, lib/getopt_int.h: Copy from gnulib.
* lib/gnulib.mk.in: Regenerate.
Diffstat (limited to 'lib/getopt.in.h')
| -rw-r--r-- | lib/getopt.in.h | 41 |
1 files changed, 30 insertions, 11 deletions
diff --git a/lib/getopt.in.h b/lib/getopt.in.h index 6cbad8e0339..3f57c68a25e 100644 --- a/lib/getopt.in.h +++ b/lib/getopt.in.h | |||
| @@ -1,20 +1,20 @@ | |||
| 1 | /* Declarations for getopt. | 1 | /* Declarations for getopt. |
| 2 | Copyright (C) 1989-1994, 1996-1999, 2001, 2003-2007, 2009-2017 Free Software | 2 | Copyright (C) 1989-2017 Free Software Foundation, Inc. |
| 3 | Foundation, Inc. | ||
| 4 | This file is part of the GNU C Library. | 3 | This file is part of the GNU C Library. |
| 5 | 4 | ||
| 6 | This program is free software: you can redistribute it and/or modify | 5 | The GNU C Library is free software; you can redistribute it and/or |
| 7 | it under the terms of the GNU General Public License as published by | 6 | modify it under the terms of the GNU General Public |
| 8 | the Free Software Foundation; either version 3 of the License, or | 7 | License as published by the Free Software Foundation; either |
| 9 | (at your option) any later version. | 8 | version 3 of the License, or (at your option) any later version. |
| 10 | 9 | ||
| 11 | This program is distributed in the hope that it will be useful, | 10 | The GNU C Library is distributed in the hope that it will be useful, |
| 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 14 | GNU General Public License for more details. | 13 | General Public License for more details. |
| 15 | 14 | ||
| 16 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public |
| 17 | along with this program. If not, see <http://www.gnu.org/licenses/>. */ | 16 | License along with the GNU C Library; if not, see |
| 17 | <http://www.gnu.org/licenses/>. */ | ||
| 18 | 18 | ||
| 19 | #ifndef _@GUARD_PREFIX@_GETOPT_H | 19 | #ifndef _@GUARD_PREFIX@_GETOPT_H |
| 20 | 20 | ||
| @@ -238,6 +238,25 @@ struct option | |||
| 238 | extern int getopt (int ___argc, char *const *___argv, const char *__shortopts) | 238 | extern int getopt (int ___argc, char *const *___argv, const char *__shortopts) |
| 239 | __THROW _GL_ARG_NONNULL ((2, 3)); | 239 | __THROW _GL_ARG_NONNULL ((2, 3)); |
| 240 | 240 | ||
| 241 | #ifndef __GETOPT_PREFIX | ||
| 242 | # if defined __need_getopt && defined __USE_POSIX2 \ | ||
| 243 | && !defined __USE_POSIX_IMPLICITLY && !defined __USE_GNU | ||
| 244 | /* The GNU getopt has more functionality than the standard version. The | ||
| 245 | additional functionality can be disable at runtime. This redirection | ||
| 246 | helps to also do this at runtime. */ | ||
| 247 | # ifdef __REDIRECT | ||
| 248 | extern int __REDIRECT_NTH (getopt, (int ___argc, char *const *___argv, | ||
| 249 | const char *__shortopts), | ||
| 250 | __posix_getopt); | ||
| 251 | # else | ||
| 252 | extern int __posix_getopt (int ___argc, char *const *___argv, | ||
| 253 | const char *__shortopts) | ||
| 254 | __THROW _GL_ARG_NONNULL ((2, 3)); | ||
| 255 | # define getopt __posix_getopt | ||
| 256 | # endif | ||
| 257 | # endif | ||
| 258 | #endif | ||
| 259 | |||
| 241 | #ifndef __need_getopt | 260 | #ifndef __need_getopt |
| 242 | extern int getopt_long (int ___argc, char *__getopt_argv_const *___argv, | 261 | extern int getopt_long (int ___argc, char *__getopt_argv_const *___argv, |
| 243 | const char *__shortopts, | 262 | const char *__shortopts, |