Blame lib/version-etc.h

Packit 6e6f77
/* Print --version and bug-reporting information in a consistent format.
Packit 6e6f77
   Copyright (C) 1999, 2003, 2005, 2009-2018 Free Software Foundation, Inc.
Packit 6e6f77
Packit 6e6f77
   This program is free software: you can redistribute it and/or modify
Packit 6e6f77
   it under the terms of the GNU General Public License as published by
Packit 6e6f77
   the Free Software Foundation; either version 3 of the License, or
Packit 6e6f77
   (at your option) any later version.
Packit 6e6f77
Packit 6e6f77
   This program is distributed in the hope that it will be useful,
Packit 6e6f77
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit 6e6f77
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
Packit 6e6f77
   GNU General Public License for more details.
Packit 6e6f77
Packit 6e6f77
   You should have received a copy of the GNU General Public License
Packit 6e6f77
   along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
Packit 6e6f77
Packit 6e6f77
/* Written by Jim Meyering. */
Packit 6e6f77
Packit 6e6f77
#ifndef VERSION_ETC_H
Packit 6e6f77
# define VERSION_ETC_H 1
Packit 6e6f77
Packit 6e6f77
# include <stdarg.h>
Packit 6e6f77
# include <stdio.h>
Packit 6e6f77
Packit 6e6f77
/* The 'sentinel' attribute was added in gcc 4.0.  */
Packit 6e6f77
#ifndef _GL_ATTRIBUTE_SENTINEL
Packit 6e6f77
# if 4 <= __GNUC__
Packit 6e6f77
#  define _GL_ATTRIBUTE_SENTINEL __attribute__ ((__sentinel__))
Packit 6e6f77
# else
Packit 6e6f77
#  define _GL_ATTRIBUTE_SENTINEL /* empty */
Packit 6e6f77
# endif
Packit 6e6f77
#endif
Packit 6e6f77
Packit 6e6f77
extern const char version_etc_copyright[];
Packit 6e6f77
Packit 6e6f77
/* The three functions below display the --version information in the
Packit 6e6f77
   standard way: command and package names, package version, followed
Packit 6e6f77
   by a short GPLv3+ notice and a list of up to 10 author names.
Packit 6e6f77
Packit 6e6f77
   If COMMAND_NAME is NULL, the PACKAGE is assumed to be the name of
Packit 6e6f77
   the program.  The formats are therefore:
Packit 6e6f77
Packit 6e6f77
   PACKAGE VERSION
Packit 6e6f77
Packit 6e6f77
   or
Packit 6e6f77
Packit 6e6f77
   COMMAND_NAME (PACKAGE) VERSION.
Packit 6e6f77
Packit 6e6f77
   The functions differ in the way they are passed author names: */
Packit 6e6f77
Packit 6e6f77
/* N_AUTHORS names are supplied in array AUTHORS.  */
Packit 6e6f77
extern void version_etc_arn (FILE *stream,
Packit 6e6f77
                             const char *command_name, const char *package,
Packit 6e6f77
                             const char *version,
Packit 6e6f77
                             const char * const * authors, size_t n_authors);
Packit 6e6f77
Packit 6e6f77
/* Names are passed in the NULL-terminated array AUTHORS.  */
Packit 6e6f77
extern void version_etc_ar (FILE *stream,
Packit 6e6f77
                            const char *command_name, const char *package,
Packit 6e6f77
                            const char *version, const char * const * authors);
Packit 6e6f77
Packit 6e6f77
/* Names are passed in the NULL-terminated va_list.  */
Packit 6e6f77
extern void version_etc_va (FILE *stream,
Packit 6e6f77
                            const char *command_name, const char *package,
Packit 6e6f77
                            const char *version, va_list authors);
Packit 6e6f77
Packit 6e6f77
/* Names are passed as separate arguments, with an additional
Packit 6e6f77
   NULL argument at the end.  */
Packit 6e6f77
extern void version_etc (FILE *stream,
Packit 6e6f77
                         const char *command_name, const char *package,
Packit 6e6f77
                         const char *version,
Packit 6e6f77
                         /* const char *author1, ..., NULL */ ...)
Packit 6e6f77
  _GL_ATTRIBUTE_SENTINEL;
Packit 6e6f77
Packit 6e6f77
/* Display the usual "Report bugs to" stanza.  */
Packit 6e6f77
extern void emit_bug_reporting_address (void);
Packit 6e6f77
Packit 6e6f77
#endif /* VERSION_ETC_H */