annotate intl/libgnuintl.h.in @ 484:fc968772e096 trunk

[svn] Remove ALL Xlib stuff from the skinning engine and use GDK where applicable instead.
author nenolod
date Mon, 23 Jan 2006 12:24:48 -0800
parents cb178e5ad177
children f12d7e208b43
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
1 /* Message catalogs for internationalization.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
2 Copyright (C) 1995-1997, 2000-2003 Free Software Foundation, Inc.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
3
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
4 This program is free software; you can redistribute it and/or modify it
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
5 under the terms of the GNU Library General Public License as published
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
6 by the Free Software Foundation; either version 2, or (at your option)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
7 any later version.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
8
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
9 This program is distributed in the hope that it will be useful,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
12 Library General Public License for more details.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
13
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
14 You should have received a copy of the GNU Library General Public
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
15 License along with this program; if not, write to the Free Software
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
16 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
17 USA. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
18
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
19 #ifndef _LIBINTL_H
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
20 #define _LIBINTL_H 1
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
21
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
22 #include <locale.h>
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
23
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
24 /* The LC_MESSAGES locale category is the category used by the functions
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
25 gettext() and dgettext(). It is specified in POSIX, but not in ANSI C.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
26 On systems that don't define it, use an arbitrary value instead.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
27 On Solaris, <locale.h> defines __LOCALE_H (or _LOCALE_H in Solaris 2.5)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
28 then includes <libintl.h> (i.e. this file!) and then only defines
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
29 LC_MESSAGES. To avoid a redefinition warning, don't define LC_MESSAGES
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
30 in this case. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
31 #if !defined LC_MESSAGES && !(defined __LOCALE_H || (defined _LOCALE_H && defined __sun))
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
32 # define LC_MESSAGES 1729
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
33 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
34
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
35 /* We define an additional symbol to signal that we use the GNU
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
36 implementation of gettext. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
37 #define __USE_GNU_GETTEXT 1
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
38
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
39 /* Provide information about the supported file formats. Returns the
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
40 maximum minor revision number supported for a given major revision. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
41 #define __GNU_GETTEXT_SUPPORTED_REVISION(major) \
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
42 ((major) == 0 ? 1 : -1)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
43
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
44 /* Resolve a platform specific conflict on DJGPP. GNU gettext takes
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
45 precedence over _conio_gettext. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
46 #ifdef __DJGPP__
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
47 # undef gettext
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
48 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
49
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
50 /* Use _INTL_PARAMS, not PARAMS, in order to avoid clashes with identifiers
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
51 used by programs. Similarly, test __PROTOTYPES, not PROTOTYPES. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
52 #ifndef _INTL_PARAMS
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
53 # if __STDC__ || defined __GNUC__ || defined __SUNPRO_C || defined __cplusplus || __PROTOTYPES
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
54 # define _INTL_PARAMS(args) args
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
55 # else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
56 # define _INTL_PARAMS(args) ()
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
57 # endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
58 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
59
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
60 #ifdef __cplusplus
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
61 extern "C" {
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
62 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
63
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
64
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
65 /* We redirect the functions to those prefixed with "libintl_". This is
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
66 necessary, because some systems define gettext/textdomain/... in the C
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
67 library (namely, Solaris 2.4 and newer, and GNU libc 2.0 and newer).
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
68 If we used the unprefixed names, there would be cases where the
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
69 definition in the C library would override the one in the libintl.so
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
70 shared library. Recall that on ELF systems, the symbols are looked
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
71 up in the following order:
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
72 1. in the executable,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
73 2. in the shared libraries specified on the link command line, in order,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
74 3. in the dependencies of the shared libraries specified on the link
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
75 command line,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
76 4. in the dlopen()ed shared libraries, in the order in which they were
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
77 dlopen()ed.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
78 The definition in the C library would override the one in libintl.so if
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
79 either
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
80 * -lc is given on the link command line and -lintl isn't, or
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
81 * -lc is given on the link command line before -lintl, or
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
82 * libintl.so is a dependency of a dlopen()ed shared library but not
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
83 linked to the executable at link time.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
84 Since Solaris gettext() behaves differently than GNU gettext(), this
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
85 would be unacceptable.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
86
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
87 The redirection happens by default through macros in C, so that &gettext
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
88 is independent of the compilation unit, but through inline functions in
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
89 C++, in order not to interfere with the name mangling of class fields or
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
90 class methods called 'gettext'. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
91
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
92 /* The user can define _INTL_REDIRECT_INLINE or _INTL_REDIRECT_MACROS.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
93 If he doesn't, we choose the method. A third possible method is
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
94 _INTL_REDIRECT_ASM, supported only by GCC. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
95 #if !(defined _INTL_REDIRECT_INLINE || defined _INTL_REDIRECT_MACROS)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
96 # if __GNUC__ >= 2 && !defined __APPLE_CC__ && (defined __STDC__ || defined __cplusplus)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
97 # define _INTL_REDIRECT_ASM
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
98 # else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
99 # ifdef __cplusplus
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
100 # define _INTL_REDIRECT_INLINE
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
101 # else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
102 # define _INTL_REDIRECT_MACROS
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
103 # endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
104 # endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
105 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
106 /* Auxiliary macros. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
107 #ifdef _INTL_REDIRECT_ASM
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
108 # define _INTL_ASM(cname) __asm__ (_INTL_ASMNAME (__USER_LABEL_PREFIX__, #cname))
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
109 # define _INTL_ASMNAME(prefix,cnamestring) _INTL_STRINGIFY (prefix) cnamestring
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
110 # define _INTL_STRINGIFY(prefix) #prefix
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
111 #else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
112 # define _INTL_ASM(cname)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
113 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
114
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
115 /* Look up MSGID in the current default message catalog for the current
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
116 LC_MESSAGES locale. If not found, returns MSGID itself (the default
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
117 text). */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
118 #ifdef _INTL_REDIRECT_INLINE
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
119 extern char *libintl_gettext (const char *__msgid);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
120 static inline char *gettext (const char *__msgid)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
121 {
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
122 return libintl_gettext (__msgid);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
123 }
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
124 #else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
125 #ifdef _INTL_REDIRECT_MACROS
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
126 # define gettext libintl_gettext
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
127 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
128 extern char *gettext _INTL_PARAMS ((const char *__msgid))
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
129 _INTL_ASM (libintl_gettext);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
130 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
131
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
132 /* Look up MSGID in the DOMAINNAME message catalog for the current
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
133 LC_MESSAGES locale. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
134 #ifdef _INTL_REDIRECT_INLINE
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
135 extern char *libintl_dgettext (const char *__domainname, const char *__msgid);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
136 static inline char *dgettext (const char *__domainname, const char *__msgid)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
137 {
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
138 return libintl_dgettext (__domainname, __msgid);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
139 }
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
140 #else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
141 #ifdef _INTL_REDIRECT_MACROS
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
142 # define dgettext libintl_dgettext
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
143 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
144 extern char *dgettext _INTL_PARAMS ((const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
145 const char *__msgid))
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
146 _INTL_ASM (libintl_dgettext);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
147 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
148
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
149 /* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
150 locale. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
151 #ifdef _INTL_REDIRECT_INLINE
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
152 extern char *libintl_dcgettext (const char *__domainname, const char *__msgid,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
153 int __category);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
154 static inline char *dcgettext (const char *__domainname, const char *__msgid,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
155 int __category)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
156 {
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
157 return libintl_dcgettext (__domainname, __msgid, __category);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
158 }
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
159 #else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
160 #ifdef _INTL_REDIRECT_MACROS
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
161 # define dcgettext libintl_dcgettext
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
162 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
163 extern char *dcgettext _INTL_PARAMS ((const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
164 const char *__msgid,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
165 int __category))
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
166 _INTL_ASM (libintl_dcgettext);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
167 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
168
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
169
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
170 /* Similar to `gettext' but select the plural form corresponding to the
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
171 number N. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
172 #ifdef _INTL_REDIRECT_INLINE
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
173 extern char *libintl_ngettext (const char *__msgid1, const char *__msgid2,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
174 unsigned long int __n);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
175 static inline char *ngettext (const char *__msgid1, const char *__msgid2,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
176 unsigned long int __n)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
177 {
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
178 return libintl_ngettext (__msgid1, __msgid2, __n);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
179 }
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
180 #else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
181 #ifdef _INTL_REDIRECT_MACROS
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
182 # define ngettext libintl_ngettext
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
183 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
184 extern char *ngettext _INTL_PARAMS ((const char *__msgid1,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
185 const char *__msgid2,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
186 unsigned long int __n))
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
187 _INTL_ASM (libintl_ngettext);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
188 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
189
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
190 /* Similar to `dgettext' but select the plural form corresponding to the
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
191 number N. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
192 #ifdef _INTL_REDIRECT_INLINE
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
193 extern char *libintl_dngettext (const char *__domainname, const char *__msgid1,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
194 const char *__msgid2, unsigned long int __n);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
195 static inline char *dngettext (const char *__domainname, const char *__msgid1,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
196 const char *__msgid2, unsigned long int __n)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
197 {
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
198 return libintl_dngettext (__domainname, __msgid1, __msgid2, __n);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
199 }
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
200 #else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
201 #ifdef _INTL_REDIRECT_MACROS
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
202 # define dngettext libintl_dngettext
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
203 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
204 extern char *dngettext _INTL_PARAMS ((const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
205 const char *__msgid1,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
206 const char *__msgid2,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
207 unsigned long int __n))
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
208 _INTL_ASM (libintl_dngettext);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
209 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
210
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
211 /* Similar to `dcgettext' but select the plural form corresponding to the
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
212 number N. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
213 #ifdef _INTL_REDIRECT_INLINE
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
214 extern char *libintl_dcngettext (const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
215 const char *__msgid1, const char *__msgid2,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
216 unsigned long int __n, int __category);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
217 static inline char *dcngettext (const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
218 const char *__msgid1, const char *__msgid2,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
219 unsigned long int __n, int __category)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
220 {
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
221 return libintl_dcngettext (__domainname, __msgid1, __msgid2, __n, __category);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
222 }
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
223 #else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
224 #ifdef _INTL_REDIRECT_MACROS
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
225 # define dcngettext libintl_dcngettext
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
226 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
227 extern char *dcngettext _INTL_PARAMS ((const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
228 const char *__msgid1,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
229 const char *__msgid2,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
230 unsigned long int __n,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
231 int __category))
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
232 _INTL_ASM (libintl_dcngettext);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
233 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
234
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
235
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
236 /* Set the current default message catalog to DOMAINNAME.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
237 If DOMAINNAME is null, return the current default.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
238 If DOMAINNAME is "", reset to the default of "messages". */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
239 #ifdef _INTL_REDIRECT_INLINE
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
240 extern char *libintl_textdomain (const char *__domainname);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
241 static inline char *textdomain (const char *__domainname)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
242 {
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
243 return libintl_textdomain (__domainname);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
244 }
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
245 #else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
246 #ifdef _INTL_REDIRECT_MACROS
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
247 # define textdomain libintl_textdomain
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
248 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
249 extern char *textdomain _INTL_PARAMS ((const char *__domainname))
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
250 _INTL_ASM (libintl_textdomain);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
251 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
252
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
253 /* Specify that the DOMAINNAME message catalog will be found
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
254 in DIRNAME rather than in the system locale data base. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
255 #ifdef _INTL_REDIRECT_INLINE
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
256 extern char *libintl_bindtextdomain (const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
257 const char *__dirname);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
258 static inline char *bindtextdomain (const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
259 const char *__dirname)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
260 {
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
261 return libintl_bindtextdomain (__domainname, __dirname);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
262 }
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
263 #else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
264 #ifdef _INTL_REDIRECT_MACROS
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
265 # define bindtextdomain libintl_bindtextdomain
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
266 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
267 extern char *bindtextdomain _INTL_PARAMS ((const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
268 const char *__dirname))
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
269 _INTL_ASM (libintl_bindtextdomain);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
270 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
271
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
272 /* Specify the character encoding in which the messages from the
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
273 DOMAINNAME message catalog will be returned. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
274 #ifdef _INTL_REDIRECT_INLINE
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
275 extern char *libintl_bind_textdomain_codeset (const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
276 const char *__codeset);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
277 static inline char *bind_textdomain_codeset (const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
278 const char *__codeset)
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
279 {
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
280 return libintl_bind_textdomain_codeset (__domainname, __codeset);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
281 }
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
282 #else
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
283 #ifdef _INTL_REDIRECT_MACROS
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
284 # define bind_textdomain_codeset libintl_bind_textdomain_codeset
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
285 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
286 extern char *bind_textdomain_codeset _INTL_PARAMS ((const char *__domainname,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
287 const char *__codeset))
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
288 _INTL_ASM (libintl_bind_textdomain_codeset);
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
289 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
290
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
291
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
292 /* Support for relocatable packages. */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
293
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
294 /* Sets the original and the current installation prefix of the package.
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
295 Relocation simply replaces a pathname starting with the original prefix
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
296 by the corresponding pathname with the current prefix instead. Both
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
297 prefixes should be directory names without trailing slash (i.e. use ""
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
298 instead of "/"). */
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
299 #define libintl_set_relocation_prefix libintl_set_relocation_prefix
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
300 extern void
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
301 libintl_set_relocation_prefix _INTL_PARAMS ((const char *orig_prefix,
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
302 const char *curr_prefix));
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
303
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
304
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
305 #ifdef __cplusplus
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
306 }
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
307 #endif
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
308
cb178e5ad177 [svn] Import audacious source.
nenolod
parents:
diff changeset
309 #endif /* libintl.h */