Blame gst-libs/gst/gettext.h

Packit 971217
/* Convenience header for conditional use of GNU <libintl.h>.
Packit 971217
   Copyright (C) 1995-1998, 2000-2002 Free Software Foundation, Inc.
Packit 971217
Packit 971217
   This program is free software; you can redistribute it and/or modify it
Packit 971217
   under the terms of the GNU Library General Public License as published
Packit 971217
   by the Free Software Foundation; either version 2, or (at your option)
Packit 971217
   any later version.
Packit 971217
Packit 971217
   This program is distributed in the hope that it will be useful,
Packit 971217
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit 971217
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit 971217
   Library General Public License for more details.
Packit 971217
Packit 971217
   You should have received a copy of the GNU Library General Public
Packit 971217
   License along with this program; if not, write to the Free Software
Packit 971217
   Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301,
Packit 971217
   USA.  */
Packit 971217
Packit 971217
#ifndef _LIBGETTEXT_H
Packit 971217
#define _LIBGETTEXT_H 1
Packit 971217
Packit 971217
/* NLS can be disabled through the configure --disable-nls option.  */
Packit 971217
#if defined (ENABLE_NLS) && ENABLE_NLS
Packit 971217
Packit 971217
/* Get declarations of GNU message catalog functions.  */
Packit 971217
# include <libintl.h>
Packit 971217
Packit 971217
#else
Packit 971217
Packit 971217
/* Solaris /usr/include/locale.h includes /usr/include/libintl.h, which
Packit 971217
   chokes if dcgettext is defined as a macro.  So include it now, to make
Packit 971217
   later inclusions of <locale.h> a NOP.  We don't include <libintl.h>
Packit 971217
   as well because people using "gettext.h" will not include <libintl.h>,
Packit 971217
   and also including <libintl.h> would fail on SunOS 4, whereas <locale.h>
Packit 971217
   is OK.  */
Packit 971217
#if defined(__sun)
Packit 971217
# include <locale.h>
Packit 971217
#endif
Packit 971217
Packit 971217
/* Disabled NLS.
Packit 971217
   The casts to 'const char *' serve the purpose of producing warnings
Packit 971217
   for invalid uses of the value returned from these functions.
Packit 971217
   On pre-ANSI systems without 'const', the config.h file is supposed to
Packit 971217
   contain "#define const".  */
Packit 971217
# define gettext(Msgid) ((const char *) (Msgid))
Packit 971217
# define dgettext(Domainname, Msgid) ((const char *) (Msgid))
Packit 971217
# define dcgettext(Domainname, Msgid, Category) ((const char *) (Msgid))
Packit 971217
# define ngettext(Msgid1, Msgid2, N) \
Packit 971217
    ((N) == 1 ? (const char *) (Msgid1) : (const char *) (Msgid2))
Packit 971217
# define dngettext(Domainname, Msgid1, Msgid2, N) \
Packit 971217
    ((N) == 1 ? (const char *) (Msgid1) : (const char *) (Msgid2))
Packit 971217
# define dcngettext(Domainname, Msgid1, Msgid2, N, Category) \
Packit 971217
    ((N) == 1 ? (const char *) (Msgid1) : (const char *) (Msgid2))
Packit 971217
# define textdomain(Domainname) ((const char *) (Domainname))
Packit 971217
# define bindtextdomain(Domainname, Dirname) ((const char *) (Dirname))
Packit 971217
# define bind_textdomain_codeset(Domainname, Codeset) ((const char *) (Codeset))
Packit 971217
Packit 971217
#endif
Packit 971217
Packit 971217
/* A pseudo function call that serves as a marker for the automated
Packit 971217
   extraction of messages, but does not call gettext().  The run-time
Packit 971217
   translation is done at a different place in the code.
Packit 971217
   The argument, String, should be a literal string.  Concatenated strings
Packit 971217
   and other string expressions won't work.
Packit 971217
   The macro's expansion is not parenthesized, so that it is suitable as
Packit 971217
   initializer for static 'char[]' or 'const char[]' variables.  */
Packit 971217
#define gettext_noop(String) String
Packit 971217
Packit 971217
#endif /* _LIBGETTEXT_H */