Blame lib/getopt-cdefs.in.h

Packit Service a2489d
/* getopt-on-non-glibc compatibility macros.
Packit Service a2489d
   Copyright (C) 1989-2018 Free Software Foundation, Inc.
Packit Service a2489d
   This file is part of gnulib.
Packit Service a2489d
   Unlike most of the getopt implementation, it is NOT shared
Packit Service a2489d
   with the GNU C Library.
Packit Service a2489d
Packit Service a2489d
   This file is free software; you can redistribute it and/or modify it
Packit Service a2489d
   under the terms of the GNU General Public License as
Packit Service a2489d
   published by the Free Software Foundation; either version 3 of
Packit Service a2489d
   the License, or (at your option) any later version.
Packit Service a2489d
Packit Service a2489d
   This file is distributed in the hope that it will be useful, but
Packit Service a2489d
   WITHOUT ANY WARRANTY; without even the implied warranty of
Packit Service a2489d
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit Service a2489d
   General Public License for more details.
Packit Service a2489d
Packit Service a2489d
   You should have received a copy of the GNU General Public
Packit Service a2489d
   License along with gnulib; if not, see
Packit Service a2489d
   <https://www.gnu.org/licenses/>.  */
Packit Service a2489d
Packit Service a2489d
#ifndef _GETOPT_CDEFS_H
Packit Service a2489d
#define _GETOPT_CDEFS_H 1
Packit Service a2489d
Packit Service a2489d
/* This header should not be used directly; include getopt.h or
Packit Service a2489d
   unistd.h instead.  It does not have a protective #error, because
Packit Service a2489d
   the guard macro for getopt.h in gnulib is not fixed.  */
Packit Service a2489d
Packit Service a2489d
/* getopt-core.h and getopt-ext.h are shared with GNU libc, and expect
Packit Service a2489d
   a number of the internal macros supplied to GNU libc's headers by
Packit Service a2489d
   sys/cdefs.h.  Provide fallback definitions for all of them.  */
Packit Service a2489d
#if @HAVE_SYS_CDEFS_H@
Packit Service a2489d
# include <sys/cdefs.h>
Packit Service a2489d
#endif
Packit Service a2489d
Packit Service a2489d
#ifndef __BEGIN_DECLS
Packit Service a2489d
# ifdef __cplusplus
Packit Service a2489d
#  define __BEGIN_DECLS extern "C" {
Packit Service a2489d
# else
Packit Service a2489d
#  define __BEGIN_DECLS /* nothing */
Packit Service a2489d
# endif
Packit Service a2489d
#endif
Packit Service a2489d
#ifndef __END_DECLS
Packit Service a2489d
# ifdef __cplusplus
Packit Service a2489d
#  define __END_DECLS }
Packit Service a2489d
# else
Packit Service a2489d
#  define __END_DECLS /* nothing */
Packit Service a2489d
# endif
Packit Service a2489d
#endif
Packit Service a2489d
Packit Service a2489d
#ifndef __GNUC_PREREQ
Packit Service a2489d
# if defined __GNUC__ && defined __GNUC_VERSION__
Packit Service a2489d
# define __GNUC_PREREQ(maj, min) \
Packit Service a2489d
        ((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
Packit Service a2489d
# else
Packit Service a2489d
#  define __GNUC_PREREQ(maj, min) 0
Packit Service a2489d
# endif
Packit Service a2489d
#endif
Packit Service a2489d
Packit Service a2489d
#ifndef __THROW
Packit Service a2489d
# if defined __cplusplus && __GNUC_PREREQ (2,8)
Packit Service a2489d
#  define __THROW       throw ()
Packit Service a2489d
# else
Packit Service a2489d
#  define __THROW
Packit Service a2489d
# endif
Packit Service a2489d
#endif
Packit Service a2489d
Packit Service a2489d
#endif /* _GETOPT_CDEFS_H */