Blame lib/iconv.in.h

Packit Service a2489d
/* A GNU-like <iconv.h>.
Packit Service a2489d
Packit Service a2489d
   Copyright (C) 2007-2018 Free Software Foundation, Inc.
Packit Service a2489d
Packit Service a2489d
   This program is free software; you can redistribute it and/or modify
Packit Service a2489d
   it under the terms of the GNU General Public License as published by
Packit Service a2489d
   the Free Software Foundation; either version 3, or (at your option)
Packit Service a2489d
   any later version.
Packit Service a2489d
Packit Service a2489d
   This program is distributed in the hope that it will be useful,
Packit Service a2489d
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit Service a2489d
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
Packit Service a2489d
   GNU General Public License for more details.
Packit Service a2489d
Packit Service a2489d
   You should have received a copy of the GNU General Public License
Packit Service a2489d
   along with this program; if not, see <https://www.gnu.org/licenses/>.  */
Packit Service a2489d
Packit Service a2489d
#ifndef _@GUARD_PREFIX@_ICONV_H
Packit Service a2489d
Packit Service a2489d
#if __GNUC__ >= 3
Packit Service a2489d
@PRAGMA_SYSTEM_HEADER@
Packit Service a2489d
#endif
Packit Service a2489d
@PRAGMA_COLUMNS@
Packit Service a2489d
Packit Service a2489d
/* The include_next requires a split double-inclusion guard.  */
Packit Service a2489d
#@INCLUDE_NEXT@ @NEXT_ICONV_H@
Packit Service a2489d
Packit Service a2489d
#ifndef _@GUARD_PREFIX@_ICONV_H
Packit Service a2489d
#define _@GUARD_PREFIX@_ICONV_H
Packit Service a2489d
Packit Service a2489d
/* The definitions of _GL_FUNCDECL_RPL etc. are copied here.  */
Packit Service a2489d
Packit Service a2489d
/* The definition of _GL_ARG_NONNULL is copied here.  */
Packit Service a2489d
Packit Service a2489d
/* The definition of _GL_WARN_ON_USE is copied here.  */
Packit Service a2489d
Packit Service a2489d
Packit Service a2489d
#if @GNULIB_ICONV@
Packit Service a2489d
# if @REPLACE_ICONV_OPEN@
Packit Service a2489d
/* An iconv_open wrapper that supports the IANA standardized encoding names
Packit Service a2489d
   ("ISO-8859-1" etc.) as far as possible.  */
Packit Service a2489d
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service a2489d
#   define iconv_open rpl_iconv_open
Packit Service a2489d
#  endif
Packit Service a2489d
_GL_FUNCDECL_RPL (iconv_open, iconv_t,
Packit Service a2489d
                  (const char *tocode, const char *fromcode)
Packit Service a2489d
                  _GL_ARG_NONNULL ((1, 2)));
Packit Service a2489d
_GL_CXXALIAS_RPL (iconv_open, iconv_t,
Packit Service a2489d
                  (const char *tocode, const char *fromcode));
Packit Service a2489d
# else
Packit Service a2489d
_GL_CXXALIAS_SYS (iconv_open, iconv_t,
Packit Service a2489d
                  (const char *tocode, const char *fromcode));
Packit Service a2489d
# endif
Packit Service a2489d
_GL_CXXALIASWARN (iconv_open);
Packit Service a2489d
#endif
Packit Service a2489d
Packit Service a2489d
#if @REPLACE_ICONV_UTF@
Packit Service a2489d
/* Special constants for supporting UTF-{16,32}{BE,LE} encodings.
Packit Service a2489d
   Not public.  */
Packit Service a2489d
# define _ICONV_UTF8_UTF16BE (iconv_t)(-161)
Packit Service a2489d
# define _ICONV_UTF8_UTF16LE (iconv_t)(-162)
Packit Service a2489d
# define _ICONV_UTF8_UTF32BE (iconv_t)(-163)
Packit Service a2489d
# define _ICONV_UTF8_UTF32LE (iconv_t)(-164)
Packit Service a2489d
# define _ICONV_UTF16BE_UTF8 (iconv_t)(-165)
Packit Service a2489d
# define _ICONV_UTF16LE_UTF8 (iconv_t)(-166)
Packit Service a2489d
# define _ICONV_UTF32BE_UTF8 (iconv_t)(-167)
Packit Service a2489d
# define _ICONV_UTF32LE_UTF8 (iconv_t)(-168)
Packit Service a2489d
#endif
Packit Service a2489d
Packit Service a2489d
#if @GNULIB_ICONV@
Packit Service a2489d
# if @REPLACE_ICONV@
Packit Service a2489d
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service a2489d
#   define iconv rpl_iconv
Packit Service a2489d
#  endif
Packit Service a2489d
_GL_FUNCDECL_RPL (iconv, size_t,
Packit Service a2489d
                  (iconv_t cd,
Packit Service a2489d
                   @ICONV_CONST@ char **inbuf, size_t *inbytesleft,
Packit Service a2489d
                   char **outbuf, size_t *outbytesleft));
Packit Service a2489d
_GL_CXXALIAS_RPL (iconv, size_t,
Packit Service a2489d
                  (iconv_t cd,
Packit Service a2489d
                   @ICONV_CONST@ char **inbuf, size_t *inbytesleft,
Packit Service a2489d
                   char **outbuf, size_t *outbytesleft));
Packit Service a2489d
# else
Packit Service a2489d
_GL_CXXALIAS_SYS (iconv, size_t,
Packit Service a2489d
                  (iconv_t cd,
Packit Service a2489d
                   @ICONV_CONST@ char **inbuf, size_t *inbytesleft,
Packit Service a2489d
                   char **outbuf, size_t *outbytesleft));
Packit Service a2489d
# endif
Packit Service a2489d
_GL_CXXALIASWARN (iconv);
Packit Service a2489d
# ifndef ICONV_CONST
Packit Service a2489d
#  define ICONV_CONST @ICONV_CONST@
Packit Service a2489d
# endif
Packit Service a2489d
#endif
Packit Service a2489d
Packit Service a2489d
#if @GNULIB_ICONV@
Packit Service a2489d
# if @REPLACE_ICONV@
Packit Service a2489d
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
Packit Service a2489d
#   define iconv_close rpl_iconv_close
Packit Service a2489d
#  endif
Packit Service a2489d
_GL_FUNCDECL_RPL (iconv_close, int, (iconv_t cd));
Packit Service a2489d
_GL_CXXALIAS_RPL (iconv_close, int, (iconv_t cd));
Packit Service a2489d
# else
Packit Service a2489d
_GL_CXXALIAS_SYS (iconv_close, int, (iconv_t cd));
Packit Service a2489d
# endif
Packit Service a2489d
_GL_CXXALIASWARN (iconv_close);
Packit Service a2489d
#endif
Packit Service a2489d
Packit Service a2489d
Packit Service a2489d
#endif /* _@GUARD_PREFIX@_ICONV_H */
Packit Service a2489d
#endif /* _@GUARD_PREFIX@_ICONV_H */