Blame lib/getopt-pfx-core.h

Packit 33f14e
/* getopt (basic, portable features) gnulib wrapper header.
Packit 33f14e
   Copyright (C) 1989-2017 Free Software Foundation, Inc.
Packit 33f14e
   This file is part of gnulib.
Packit 33f14e
   Unlike most of the getopt implementation, it is NOT shared
Packit 33f14e
   with the GNU C Library.
Packit 33f14e
Packit 33f14e
   gnulib is free software; you can redistribute it and/or modify it
Packit 33f14e
   under the terms of the GNU General Public License as
Packit 33f14e
   published by the Free Software Foundation; either version 3 of
Packit 33f14e
   the License, or (at your option) any later version.
Packit 33f14e
Packit 33f14e
   gnulib is distributed in the hope that it will be useful, but
Packit 33f14e
   WITHOUT ANY WARRANTY; without even the implied warranty of
Packit 33f14e
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit 33f14e
   General Public License for more details.
Packit 33f14e
Packit 33f14e
   You should have received a copy of the GNU General Public
Packit 33f14e
   License along with gnulib; if not, see
Packit 33f14e
   <http://www.gnu.org/licenses/>.  */
Packit 33f14e
Packit 33f14e
#ifndef _GETOPT_PFX_CORE_H
Packit 33f14e
#define _GETOPT_PFX_CORE_H 1
Packit 33f14e
Packit 33f14e
/* This header should not be used directly; include getopt.h or
Packit 33f14e
   unistd.h instead.  It does not have a protective #error, because
Packit 33f14e
   the guard macro for getopt.h in gnulib is not fixed.  */
Packit 33f14e
Packit 33f14e
/* Standalone applications should #define __GETOPT_PREFIX to an
Packit 33f14e
   identifier that prefixes the external functions and variables
Packit 33f14e
   defined in getopt-core.h and getopt-ext.h.  Systematically
Packit 33f14e
   rename identifiers so that they do not collide with the system
Packit 33f14e
   functions and variables.  Renaming avoids problems with some
Packit 33f14e
   compilers and linkers.  */
Packit 33f14e
#ifdef __GETOPT_PREFIX
Packit 33f14e
# ifndef __GETOPT_ID
Packit 33f14e
#  define __GETOPT_CONCAT(x, y) x ## y
Packit 33f14e
#  define __GETOPT_XCONCAT(x, y) __GETOPT_CONCAT (x, y)
Packit 33f14e
#  define __GETOPT_ID(y) __GETOPT_XCONCAT (__GETOPT_PREFIX, y)
Packit 33f14e
# endif
Packit 33f14e
# undef getopt
Packit 33f14e
# undef optarg
Packit 33f14e
# undef opterr
Packit 33f14e
# undef optind
Packit 33f14e
# undef optopt
Packit 33f14e
# define getopt __GETOPT_ID (getopt)
Packit 33f14e
# define optarg __GETOPT_ID (optarg)
Packit 33f14e
# define opterr __GETOPT_ID (opterr)
Packit 33f14e
# define optind __GETOPT_ID (optind)
Packit 33f14e
# define optopt __GETOPT_ID (optopt)
Packit 33f14e
#endif
Packit 33f14e
Packit 33f14e
#include <getopt-core.h>
Packit 33f14e
Packit 33f14e
#endif /* _GETOPT_PFX_CORE_H */