Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-17 09:55:47

0001 /* Message catalogs for internationalization.
0002    Copyright (C) 1995-1997, 2000-2016, 2018-2024 Free Software Foundation, Inc.
0003 
0004    This program is free software: you can redistribute it and/or modify
0005    it under the terms of the GNU Lesser General Public License as published by
0006    the Free Software Foundation; either version 2.1 of the License, or
0007    (at your option) any later version.
0008 
0009    This program is distributed in the hope that it will be useful,
0010    but WITHOUT ANY WARRANTY; without even the implied warranty of
0011    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
0012    GNU Lesser General Public License for more details.
0013 
0014    You should have received a copy of the GNU Lesser General Public License
0015    along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
0016 
0017 #ifndef _LIBINTL_H
0018 #define _LIBINTL_H 1
0019 
0020 #include <locale.h>
0021 #if (defined __APPLE__ && defined __MACH__) && 1
0022 # include <xlocale.h>
0023 #endif
0024 
0025 /* The LC_MESSAGES locale category is the category used by the functions
0026    gettext() and dgettext().  It is specified in POSIX, but not in ANSI C.
0027    On systems that don't define it, use an arbitrary value instead.
0028    On Solaris, <locale.h> defines __LOCALE_H (or _LOCALE_H in Solaris 2.5)
0029    then includes <libintl.h> (i.e. this file!) and then only defines
0030    LC_MESSAGES.  To avoid a redefinition warning, don't define LC_MESSAGES
0031    in this case.  */
0032 #if !defined LC_MESSAGES && !(defined __LOCALE_H || (defined _LOCALE_H && defined __sun))
0033 # define LC_MESSAGES 1729
0034 #endif
0035 
0036 /* We define an additional symbol to signal that we use the GNU
0037    implementation of gettext.  */
0038 #define __USE_GNU_GETTEXT 1
0039 
0040 /* Provide information about the supported file formats.  Returns the
0041    maximum minor revision number supported for a given major revision.  */
0042 #define __GNU_GETTEXT_SUPPORTED_REVISION(major) \
0043   ((major) == 0 || (major) == 1 ? 1 : -1)
0044 
0045 /* Resolve a platform specific conflict on DJGPP.  GNU gettext takes
0046    precedence over _conio_gettext.  */
0047 #ifdef __DJGPP__
0048 # undef gettext
0049 #endif
0050 
0051 #ifdef __cplusplus
0052 extern "C" {
0053 #endif
0054 
0055 
0056 /* Version number: (major<<16) + (minor<<8) + subminor */
0057 #define LIBINTL_VERSION 0x001605
0058 extern int libintl_version;
0059 
0060 
0061 /* We redirect the functions to those prefixed with "libintl_".  This is
0062    necessary, because some systems define gettext/textdomain/... in the C
0063    library (namely, Solaris 2.4 and newer, and GNU libc 2.0 and newer).
0064    If we used the unprefixed names, there would be cases where the
0065    definition in the C library would override the one in the libintl.so
0066    shared library.  Recall that on ELF systems, the symbols are looked
0067    up in the following order:
0068      1. in the executable,
0069      2. in the shared libraries specified on the link command line, in order,
0070      3. in the dependencies of the shared libraries specified on the link
0071         command line,
0072      4. in the dlopen()ed shared libraries, in the order in which they were
0073         dlopen()ed.
0074    The definition in the C library would override the one in libintl.so if
0075    either
0076      * -lc is given on the link command line and -lintl isn't, or
0077      * -lc is given on the link command line before -lintl, or
0078      * libintl.so is a dependency of a dlopen()ed shared library but not
0079        linked to the executable at link time.
0080    Since Solaris gettext() behaves differently than GNU gettext(), this
0081    would be unacceptable.
0082 
0083    The redirection happens by default through macros in C, so that &gettext
0084    is independent of the compilation unit, but through inline functions in
0085    C++, in order not to interfere with the name mangling of class fields or
0086    class methods called 'gettext'.  */
0087 
0088 /* The user can define _INTL_REDIRECT_INLINE or _INTL_REDIRECT_MACROS.
0089    If he doesn't, we choose the method.  A third possible method is
0090    _INTL_REDIRECT_ASM, supported only by GCC.  */
0091 #if !(defined _INTL_REDIRECT_INLINE || defined _INTL_REDIRECT_MACROS)
0092 # if defined __GNUC__ && __GNUC__ >= 2 && !(defined __APPLE_CC__ && __APPLE_CC__ > 1) && !defined __MINGW32__ && !(__GNUC__ == 2 && defined _AIX) && (defined __STDC__ || defined __cplusplus)
0093 #  define _INTL_REDIRECT_ASM
0094 # else
0095 #  ifdef __cplusplus
0096 #   define _INTL_REDIRECT_INLINE
0097 #  else
0098 #   define _INTL_REDIRECT_MACROS
0099 #  endif
0100 # endif
0101 #endif
0102 /* Auxiliary macros.  */
0103 #ifdef _INTL_REDIRECT_ASM
0104 # define _INTL_ASM(cname) __asm__ (_INTL_ASMNAME (__USER_LABEL_PREFIX__, #cname))
0105 # define _INTL_ASMNAME(prefix,cnamestring) _INTL_STRINGIFY (prefix) cnamestring
0106 # define _INTL_STRINGIFY(prefix) #prefix
0107 #else
0108 # define _INTL_ASM(cname)
0109 #endif
0110 
0111 /* _INTL_MAY_RETURN_STRING_ARG(n) declares that the given function may return
0112    its n-th argument literally.  This enables GCC to warn for example about
0113    printf (gettext ("foo %y")).  */
0114 #if defined __GNUC__ && __GNUC__ >= 3 && !(defined __APPLE_CC__ && __APPLE_CC__ > 1 && !(defined __clang__ && __clang__ && __clang_major__ >= 3) && defined __cplusplus)
0115 # define _INTL_MAY_RETURN_STRING_ARG(n) __attribute__ ((__format_arg__ (n)))
0116 #else
0117 # define _INTL_MAY_RETURN_STRING_ARG(n)
0118 #endif
0119 
0120 /* _INTL_ATTRIBUTE_FORMAT ((ARCHETYPE, STRING-INDEX, FIRST-TO-CHECK))
0121    declares that the STRING-INDEXth function argument is a format string of
0122    style ARCHETYPE, which is one of:
0123      printf, gnu_printf
0124      scanf, gnu_scanf,
0125      strftime, gnu_strftime,
0126      strfmon,
0127    or the same thing prefixed and suffixed with '__'.
0128    If FIRST-TO-CHECK is not 0, arguments starting at FIRST-TO_CHECK
0129    are suitable for the format string.  */
0130 /* Applies to: functions.  */
0131 #if (defined __GNUC__ && __GNUC__ + (__GNUC_MINOR__ >= 7) > 2) || defined __clang__
0132 # define _INTL_ATTRIBUTE_FORMAT(spec) __attribute__ ((__format__ spec))
0133 #else
0134 # define _INTL_ATTRIBUTE_FORMAT(spec)
0135 #endif
0136 
0137 /* _INTL_ATTRIBUTE_SPEC_PRINTF_STANDARD
0138    An __attribute__ __format__ specifier for a function that takes a format
0139    string and arguments, where the format string directives are the ones
0140    standardized by ISO C99 and POSIX.  */
0141 /* __gnu_printf__ is supported in GCC >= 4.4.  */
0142 #if defined __GNUC__ && __GNUC__ + (__GNUC_MINOR__ >= 4) > 4
0143 # define _INTL_ATTRIBUTE_SPEC_PRINTF_STANDARD __gnu_printf__
0144 #else
0145 # define _INTL_ATTRIBUTE_SPEC_PRINTF_STANDARD __printf__
0146 #endif
0147 
0148 /* _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD
0149    indicates to GCC that the function takes a format string and arguments,
0150    where the format string directives are the ones standardized by ISO C99
0151    and POSIX.  */
0152 #define _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD(formatstring_parameter, first_argument) \
0153   _INTL_ATTRIBUTE_FORMAT ((_INTL_ATTRIBUTE_SPEC_PRINTF_STANDARD, formatstring_parameter, first_argument))
0154 
0155 /* Look up MSGID in the current default message catalog for the current
0156    LC_MESSAGES locale.  If not found, returns MSGID itself (the default
0157    text).  */
0158 #ifdef _INTL_REDIRECT_INLINE
0159 extern char *libintl_gettext (const char *__msgid)
0160        _INTL_MAY_RETURN_STRING_ARG (1);
0161 static inline
0162 _INTL_MAY_RETURN_STRING_ARG (1)
0163 char *gettext (const char *__msgid)
0164 {
0165   return libintl_gettext (__msgid);
0166 }
0167 #else
0168 # ifdef _INTL_REDIRECT_MACROS
0169 #  define gettext libintl_gettext
0170 # endif
0171 extern char *gettext (const char *__msgid)
0172        _INTL_ASM (libintl_gettext)
0173        _INTL_MAY_RETURN_STRING_ARG (1);
0174 #endif
0175 
0176 /* Look up MSGID in the DOMAINNAME message catalog for the current
0177    LC_MESSAGES locale.  */
0178 #ifdef _INTL_REDIRECT_INLINE
0179 extern char *libintl_dgettext (const char *__domainname, const char *__msgid)
0180        _INTL_MAY_RETURN_STRING_ARG (2);
0181 static inline
0182 _INTL_MAY_RETURN_STRING_ARG (2)
0183 char *dgettext (const char *__domainname, const char *__msgid)
0184 {
0185   return libintl_dgettext (__domainname, __msgid);
0186 }
0187 #else
0188 # ifdef _INTL_REDIRECT_MACROS
0189 #  define dgettext libintl_dgettext
0190 # endif
0191 extern char *dgettext (const char *__domainname, const char *__msgid)
0192        _INTL_ASM (libintl_dgettext)
0193        _INTL_MAY_RETURN_STRING_ARG (2);
0194 #endif
0195 
0196 /* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY
0197    locale.  */
0198 #ifdef _INTL_REDIRECT_INLINE
0199 extern char *libintl_dcgettext (const char *__domainname, const char *__msgid,
0200                                 int __category)
0201        _INTL_MAY_RETURN_STRING_ARG (2);
0202 static inline
0203 _INTL_MAY_RETURN_STRING_ARG (2)
0204 char *dcgettext (const char *__domainname, const char *__msgid, int __category)
0205 {
0206   return libintl_dcgettext (__domainname, __msgid, __category);
0207 }
0208 #else
0209 # ifdef _INTL_REDIRECT_MACROS
0210 #  define dcgettext libintl_dcgettext
0211 # endif
0212 extern char *dcgettext (const char *__domainname, const char *__msgid,
0213                         int __category)
0214        _INTL_ASM (libintl_dcgettext)
0215        _INTL_MAY_RETURN_STRING_ARG (2);
0216 #endif
0217 
0218 
0219 /* Similar to 'gettext' but select the plural form corresponding to the
0220    number N.  */
0221 #ifdef _INTL_REDIRECT_INLINE
0222 extern char *libintl_ngettext (const char *__msgid1, const char *__msgid2,
0223                                unsigned long int __n)
0224        _INTL_MAY_RETURN_STRING_ARG (1) _INTL_MAY_RETURN_STRING_ARG (2);
0225 static inline
0226 _INTL_MAY_RETURN_STRING_ARG (1) _INTL_MAY_RETURN_STRING_ARG (2)
0227 char *ngettext (const char *__msgid1, const char *__msgid2,
0228                 unsigned long int __n)
0229 {
0230   return libintl_ngettext (__msgid1, __msgid2, __n);
0231 }
0232 #else
0233 # ifdef _INTL_REDIRECT_MACROS
0234 #  define ngettext libintl_ngettext
0235 # endif
0236 extern char *ngettext (const char *__msgid1, const char *__msgid2,
0237                        unsigned long int __n)
0238        _INTL_ASM (libintl_ngettext)
0239        _INTL_MAY_RETURN_STRING_ARG (1) _INTL_MAY_RETURN_STRING_ARG (2);
0240 #endif
0241 
0242 /* Similar to 'dgettext' but select the plural form corresponding to the
0243    number N.  */
0244 #ifdef _INTL_REDIRECT_INLINE
0245 extern char *libintl_dngettext (const char *__domainname, const char *__msgid1,
0246                                 const char *__msgid2, unsigned long int __n)
0247        _INTL_MAY_RETURN_STRING_ARG (2) _INTL_MAY_RETURN_STRING_ARG (3);
0248 static inline
0249 _INTL_MAY_RETURN_STRING_ARG (2) _INTL_MAY_RETURN_STRING_ARG (3)
0250 char *dngettext (const char *__domainname, const char *__msgid1,
0251                  const char *__msgid2, unsigned long int __n)
0252 {
0253   return libintl_dngettext (__domainname, __msgid1, __msgid2, __n);
0254 }
0255 #else
0256 # ifdef _INTL_REDIRECT_MACROS
0257 #  define dngettext libintl_dngettext
0258 # endif
0259 extern char *dngettext (const char *__domainname,
0260                         const char *__msgid1, const char *__msgid2,
0261                         unsigned long int __n)
0262        _INTL_ASM (libintl_dngettext)
0263        _INTL_MAY_RETURN_STRING_ARG (2) _INTL_MAY_RETURN_STRING_ARG (3);
0264 #endif
0265 
0266 /* Similar to 'dcgettext' but select the plural form corresponding to the
0267    number N.  */
0268 #ifdef _INTL_REDIRECT_INLINE
0269 extern char *libintl_dcngettext (const char *__domainname,
0270                                  const char *__msgid1, const char *__msgid2,
0271                                  unsigned long int __n, int __category)
0272        _INTL_MAY_RETURN_STRING_ARG (2) _INTL_MAY_RETURN_STRING_ARG (3);
0273 static inline
0274 _INTL_MAY_RETURN_STRING_ARG (2) _INTL_MAY_RETURN_STRING_ARG (3)
0275 char *dcngettext (const char *__domainname,
0276                   const char *__msgid1, const char *__msgid2,
0277                   unsigned long int __n, int __category)
0278 {
0279   return libintl_dcngettext (__domainname, __msgid1, __msgid2, __n, __category);
0280 }
0281 #else
0282 # ifdef _INTL_REDIRECT_MACROS
0283 #  define dcngettext libintl_dcngettext
0284 # endif
0285 extern char *dcngettext (const char *__domainname,
0286                          const char *__msgid1, const char *__msgid2,
0287                          unsigned long int __n, int __category)
0288        _INTL_ASM (libintl_dcngettext)
0289        _INTL_MAY_RETURN_STRING_ARG (2) _INTL_MAY_RETURN_STRING_ARG (3);
0290 #endif
0291 
0292 
0293 
0294 /* Set the current default message catalog to DOMAINNAME.
0295    If DOMAINNAME is null, return the current default.
0296    If DOMAINNAME is "", reset to the default of "messages".  */
0297 # ifdef _INTL_REDIRECT_INLINE
0298 extern char *libintl_textdomain (const char *__domainname);
0299 static inline char *textdomain (const char *__domainname)
0300 {
0301   return libintl_textdomain (__domainname);
0302 }
0303 # else
0304 #  ifdef _INTL_REDIRECT_MACROS
0305 #   define textdomain libintl_textdomain
0306 #  endif
0307 extern char *textdomain (const char *__domainname)
0308        _INTL_ASM (libintl_textdomain);
0309 # endif
0310 
0311 /* Specify that the DOMAINNAME message catalog will be found
0312    in DIRNAME rather than in the system locale data base.  */
0313 # ifdef _INTL_REDIRECT_INLINE
0314 extern char *libintl_bindtextdomain (const char *__domainname,
0315                                      const char *__dirname);
0316 static inline char *bindtextdomain (const char *__domainname,
0317                                     const char *__dirname)
0318 {
0319   return libintl_bindtextdomain (__domainname, __dirname);
0320 }
0321 # else
0322 #  ifdef _INTL_REDIRECT_MACROS
0323 #   define bindtextdomain libintl_bindtextdomain
0324 #  endif
0325 extern char *bindtextdomain (const char *__domainname, const char *__dirname)
0326        _INTL_ASM (libintl_bindtextdomain);
0327 # endif
0328 
0329 # if defined _WIN32 && !defined __CYGWIN__
0330 /* Specify that the DOMAINNAME message catalog will be found
0331    in WDIRNAME rather than in the system locale data base.  */
0332 #  ifdef _INTL_REDIRECT_INLINE
0333 extern wchar_t *libintl_wbindtextdomain (const char *__domainname,
0334                                          const wchar_t *__wdirname);
0335 static inline wchar_t *wbindtextdomain (const char *__domainname,
0336                                         const wchar_t *__wdirname)
0337 {
0338   return libintl_wbindtextdomain (__domainname, __wdirname);
0339 }
0340 #  else
0341 #   ifdef _INTL_REDIRECT_MACROS
0342 #    define wbindtextdomain libintl_wbindtextdomain
0343 #   endif
0344 extern wchar_t *wbindtextdomain (const char *__domainname,
0345                                  const wchar_t *__wdirname)
0346        _INTL_ASM (libintl_wbindtextdomain);
0347 #  endif
0348 # endif
0349 
0350 /* Specify the character encoding in which the messages from the
0351    DOMAINNAME message catalog will be returned.  */
0352 # ifdef _INTL_REDIRECT_INLINE
0353 extern char *libintl_bind_textdomain_codeset (const char *__domainname,
0354                                               const char *__codeset);
0355 static inline char *bind_textdomain_codeset (const char *__domainname,
0356                                              const char *__codeset)
0357 {
0358   return libintl_bind_textdomain_codeset (__domainname, __codeset);
0359 }
0360 # else
0361 #  ifdef _INTL_REDIRECT_MACROS
0362 #   define bind_textdomain_codeset libintl_bind_textdomain_codeset
0363 #  endif
0364 extern char *bind_textdomain_codeset (const char *__domainname,
0365                                       const char *__codeset)
0366        _INTL_ASM (libintl_bind_textdomain_codeset);
0367 # endif
0368 
0369 
0370 
0371 /* Support for format strings with positions in *printf(), following the
0372    POSIX/XSI specification.
0373    Note: These replacements for the *printf() functions are visible only
0374    in source files that #include <libintl.h> or #include "gettext.h".
0375    Packages that use *printf() in source files that don't refer to _()
0376    or gettext() but for which the format string could be the return value
0377    of _() or gettext() need to add this #include.  Oh well.  */
0378 
0379 /* Note: In C++ mode, it is not sufficient to redefine a symbol at the
0380    preprocessor macro level, such as
0381      #define sprintf libintl_sprintf
0382    Some programs may reference std::sprintf after including <libintl.h>.
0383    Therefore we must make sure that std::libintl_sprintf is defined and
0384    identical to ::libintl_sprintf.
0385    The user can define _INTL_CXX_NO_CLOBBER_STD_NAMESPACE to avoid this.
0386    In such cases, they will not benefit from the overrides when using
0387    the 'std' namespace, and they will need to do the references to the
0388    'std' namespace *before* including <libintl.h> or "gettext.h".  */
0389 
0390 #if !1
0391 
0392 # include <stdio.h>
0393 # include <stddef.h>
0394 
0395 /* Get va_list.  */
0396 # if (defined __STDC__ && __STDC__) || defined __cplusplus || defined _MSC_VER
0397 #  include <stdarg.h>
0398 # else
0399 #  include <varargs.h>
0400 # endif
0401 
0402 # if !((defined fprintf && defined _GL_STDIO_H) || defined GNULIB_overrides_fprintf) /* don't override gnulib */
0403 #  undef fprintf
0404 #  define fprintf libintl_fprintf
0405 extern int fprintf (FILE *, const char *, ...)
0406   _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD (2, 3);
0407 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0408 namespace std { using ::libintl_fprintf; }
0409 #  endif
0410 # endif
0411 # if !((defined vfprintf && defined _GL_STDIO_H) || defined GNULIB_overrides_vfprintf) /* don't override gnulib */
0412 #  undef vfprintf
0413 #  define vfprintf libintl_vfprintf
0414 extern int vfprintf (FILE *, const char *, va_list)
0415   _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD (2, 0);
0416 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0417 namespace std { using ::libintl_vfprintf; }
0418 #  endif
0419 # endif
0420 
0421 # if !((defined printf && defined _GL_STDIO_H) || defined GNULIB_overrides_printf) /* don't override gnulib */
0422 #  undef printf
0423 #  if defined __NetBSD__ || defined __BEOS__ || defined __CYGWIN__ || defined __MINGW32__
0424 /* Don't break __attribute__((format(printf,M,N))).
0425    This redefinition is only possible because the libc in NetBSD, Cygwin,
0426    mingw does not have a function __printf__.
0427    Alternatively, we could have done this redirection only when compiling with
0428    __GNUC__, together with a symbol redirection:
0429        extern int printf (const char *, ...)
0430               __asm__ (#__USER_LABEL_PREFIX__ "libintl_printf");
0431    But doing it now would introduce a binary incompatibility with already
0432    distributed versions of libintl on these systems.  */
0433 #   define libintl_printf __printf__
0434 #  endif
0435 #  define printf libintl_printf
0436 extern int printf (const char *, ...)
0437   _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD (1, 2);
0438 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0439 namespace std { using ::libintl_printf; }
0440 #  endif
0441 # endif
0442 # if !((defined vprintf && defined _GL_STDIO_H) || defined GNULIB_overrides_vprintf) /* don't override gnulib */
0443 #  undef vprintf
0444 #  define vprintf libintl_vprintf
0445 extern int vprintf (const char *, va_list)
0446   _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD (1, 0);
0447 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0448 namespace std { using ::libintl_vprintf; }
0449 #  endif
0450 # endif
0451 
0452 # if !((defined sprintf && defined _GL_STDIO_H) || defined GNULIB_overrides_sprintf) /* don't override gnulib */
0453 #  undef sprintf
0454 #  define sprintf libintl_sprintf
0455 extern int sprintf (char *, const char *, ...)
0456   _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD (2, 3);
0457 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0458 namespace std { using ::libintl_sprintf; }
0459 #  endif
0460 # endif
0461 # if !((defined vsprintf && defined _GL_STDIO_H) || defined GNULIB_overrides_vsprintf) /* don't override gnulib */
0462 #  undef vsprintf
0463 #  define vsprintf libintl_vsprintf
0464 extern int vsprintf (char *, const char *, va_list)
0465   _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD (2, 0);
0466 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0467 namespace std { using ::libintl_vsprintf; }
0468 #  endif
0469 # endif
0470 
0471 # if 1
0472 
0473 #  if !((defined snprintf && defined _GL_STDIO_H) || defined GNULIB_overrides_snprintf) /* don't override gnulib */
0474 #   undef snprintf
0475 #   define snprintf libintl_snprintf
0476 extern int snprintf (char *, size_t, const char *, ...)
0477   _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD (3, 4);
0478 #   if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0479 namespace std { using ::libintl_snprintf; }
0480 #   endif
0481 #  endif
0482 #  if !((defined vsnprintf && defined _GL_STDIO_H) || defined GNULIB_overrides_vsnprintf) /* don't override gnulib */
0483 #   undef vsnprintf
0484 #   define vsnprintf libintl_vsnprintf
0485 extern int vsnprintf (char *, size_t, const char *, va_list)
0486   _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD (3, 0);
0487 #   if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0488 namespace std { using ::libintl_vsnprintf; }
0489 #   endif
0490 #  endif
0491 
0492 # endif
0493 
0494 # if 1
0495 
0496 #  if !((defined asprintf && defined _GL_STDIO_H) || defined GNULIB_overrides_asprintf) /* don't override gnulib */
0497 #   undef asprintf
0498 #   define asprintf libintl_asprintf
0499 extern int asprintf (char **, const char *, ...)
0500   _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD (2, 3);
0501 #   if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0502 namespace std { using ::libintl_asprintf; }
0503 #   endif
0504 #  endif
0505 #  if !((defined vasprintf && defined _GL_STDIO_H) || defined GNULIB_overrides_vasprintf) /* don't override gnulib */
0506 #   undef vasprintf
0507 #   define vasprintf libintl_vasprintf
0508 extern int vasprintf (char **, const char *, va_list)
0509   _INTL_ATTRIBUTE_FORMAT_PRINTF_STANDARD (2, 0);
0510 #   if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0511 namespace std { using ::libintl_vasprintf; }
0512 #   endif
0513 #  endif
0514 
0515 # endif
0516 
0517 # if 1
0518 
0519 #  undef fwprintf
0520 #  define fwprintf libintl_fwprintf
0521 extern int fwprintf (FILE *, const wchar_t *, ...);
0522 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0523 namespace std { using ::libintl_fwprintf; }
0524 #  endif
0525 #  undef vfwprintf
0526 #  define vfwprintf libintl_vfwprintf
0527 extern int vfwprintf (FILE *, const wchar_t *, va_list);
0528 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0529 namespace std { using ::libintl_vfwprintf; }
0530 #  endif
0531 
0532 #  undef wprintf
0533 #  define wprintf libintl_wprintf
0534 extern int wprintf (const wchar_t *, ...);
0535 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0536 namespace std { using ::libintl_wprintf; }
0537 #  endif
0538 #  undef vwprintf
0539 #  define vwprintf libintl_vwprintf
0540 extern int vwprintf (const wchar_t *, va_list);
0541 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0542 namespace std { using ::libintl_vwprintf; }
0543 #  endif
0544 
0545 #  undef swprintf
0546 #  define swprintf libintl_swprintf
0547 extern int swprintf (wchar_t *, size_t, const wchar_t *, ...);
0548 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0549 namespace std { using ::libintl_swprintf; }
0550 #  endif
0551 #  undef vswprintf
0552 #  define vswprintf libintl_vswprintf
0553 extern int vswprintf (wchar_t *, size_t, const wchar_t *, va_list);
0554 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0555 namespace std { using ::libintl_vswprintf; }
0556 #  endif
0557 
0558 # endif
0559 
0560 #endif
0561 
0562 
0563 /* Support for retrieving the name of a locale_t object.  */
0564 #if 0
0565 
0566 # ifndef GNULIB_defined_newlocale /* don't override gnulib */
0567 #  undef newlocale
0568 #  define newlocale libintl_newlocale
0569 extern locale_t newlocale (int, const char *, locale_t);
0570 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0571 namespace std { using ::libintl_newlocale; }
0572 #  endif
0573 # endif
0574 
0575 # ifndef GNULIB_defined_duplocale /* don't override gnulib */
0576 #  undef duplocale
0577 #  define duplocale libintl_duplocale
0578 extern locale_t duplocale (locale_t);
0579 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0580 namespace std { using ::libintl_duplocale; }
0581 #  endif
0582 # endif
0583 
0584 # ifndef GNULIB_defined_freelocale /* don't override gnulib */
0585 #  undef freelocale
0586 #  define freelocale libintl_freelocale
0587 extern void freelocale (locale_t);
0588 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0589 namespace std { using ::libintl_freelocale; }
0590 #  endif
0591 # endif
0592 
0593 #endif
0594 
0595 
0596 /* Support for the locale chosen by the user.  */
0597 #if (defined __APPLE__ && defined __MACH__) || defined _WIN32 || defined __CYGWIN__
0598 
0599 # ifndef GNULIB_defined_setlocale /* don't override gnulib */
0600 #  undef setlocale
0601 #  define setlocale libintl_setlocale
0602 extern char *setlocale (int, const char *);
0603 #  if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0604 namespace std { using ::libintl_setlocale; }
0605 #  endif
0606 # endif
0607 
0608 # if 1
0609 
0610 #  undef newlocale
0611 #  define newlocale libintl_newlocale
0612 /* Declare newlocale() only if the system headers define the 'locale_t' type. */
0613 #  if !(defined __CYGWIN__ && !defined LC_ALL_MASK)
0614 extern locale_t newlocale (int, const char *, locale_t);
0615 #   if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
0616 namespace std { using ::libintl_newlocale; }
0617 #   endif
0618 #  endif
0619 
0620 # endif
0621 
0622 #endif
0623 
0624 
0625 /* Support for relocatable packages.  */
0626 
0627 /* Sets the original and the current installation prefix of the package.
0628    Relocation simply replaces a pathname starting with the original prefix
0629    by the corresponding pathname with the current prefix instead.  Both
0630    prefixes should be directory names without trailing slash (i.e. use ""
0631    instead of "/").  */
0632 #define libintl_set_relocation_prefix libintl_set_relocation_prefix
0633 extern void
0634        libintl_set_relocation_prefix (const char *orig_prefix,
0635                                       const char *curr_prefix);
0636 
0637 
0638 #ifdef __cplusplus
0639 }
0640 #endif
0641 
0642 #endif /* libintl.h */