| 1 | /* Declarations for getopt.
|
|---|
| 2 | Copyright (C) 1989-2021 Free Software Foundation, Inc.
|
|---|
| 3 | This file is part of gnulib.
|
|---|
| 4 | Unlike most of the getopt implementation, it is NOT shared
|
|---|
| 5 | with the GNU C Library, which supplies a different version of
|
|---|
| 6 | this file.
|
|---|
| 7 |
|
|---|
| 8 | This file is free software: you can redistribute it and/or modify
|
|---|
| 9 | it under the terms of the GNU Lesser General Public License as
|
|---|
| 10 | published by the Free Software Foundation; either version 2.1 of the
|
|---|
| 11 | License, or (at your option) any later version.
|
|---|
| 12 |
|
|---|
| 13 | This file is distributed in the hope that it will be useful,
|
|---|
| 14 | but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|---|
| 15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|---|
| 16 | GNU Lesser General Public License for more details.
|
|---|
| 17 |
|
|---|
| 18 | You should have received a copy of the GNU Lesser General Public License
|
|---|
| 19 | along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
|---|
| 20 |
|
|---|
| 21 | #ifndef _@GUARD_PREFIX@_GETOPT_H
|
|---|
| 22 |
|
|---|
| 23 | #if __GNUC__ >= 3
|
|---|
| 24 | @PRAGMA_SYSTEM_HEADER@
|
|---|
| 25 | #endif
|
|---|
| 26 | @PRAGMA_COLUMNS@
|
|---|
| 27 |
|
|---|
| 28 | /* The include_next requires a split double-inclusion guard. We must
|
|---|
| 29 | also inform the replacement unistd.h to not recursively use
|
|---|
| 30 | <getopt.h>; our definitions will be present soon enough. */
|
|---|
| 31 | #if @HAVE_GETOPT_H@
|
|---|
| 32 | # define _GL_SYSTEM_GETOPT
|
|---|
| 33 | # @INCLUDE_NEXT@ @NEXT_GETOPT_H@
|
|---|
| 34 | # undef _GL_SYSTEM_GETOPT
|
|---|
| 35 | #endif
|
|---|
| 36 |
|
|---|
| 37 | #define _@GUARD_PREFIX@_GETOPT_H 1
|
|---|
| 38 |
|
|---|
| 39 | /* Standalone applications should #define __GETOPT_PREFIX to an
|
|---|
| 40 | identifier that prefixes the external functions and variables
|
|---|
| 41 | defined in getopt-core.h and getopt-ext.h. When this happens,
|
|---|
| 42 | include the headers that might declare getopt so that they will not
|
|---|
| 43 | cause confusion if included after this file (if the system had
|
|---|
| 44 | <getopt.h>, we have already included it). */
|
|---|
| 45 | #if defined __GETOPT_PREFIX
|
|---|
| 46 | # if !@HAVE_GETOPT_H@
|
|---|
| 47 | # define __need_system_stdlib_h
|
|---|
| 48 | # include <stdlib.h>
|
|---|
| 49 | # undef __need_system_stdlib_h
|
|---|
| 50 | # include <stdio.h>
|
|---|
| 51 | # include <unistd.h>
|
|---|
| 52 | # endif
|
|---|
| 53 | #endif
|
|---|
| 54 |
|
|---|
| 55 | /* The definition of _GL_ARG_NONNULL is copied here. */
|
|---|
| 56 |
|
|---|
| 57 | #include <getopt-cdefs.h>
|
|---|
| 58 | #include <getopt-pfx-core.h>
|
|---|
| 59 | #include <getopt-pfx-ext.h>
|
|---|
| 60 |
|
|---|
| 61 | #endif /* _@GUARD_PREFIX@_GETOPT_H */
|
|---|