The R Project SVN R

Rev

Rev 42713 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 42713 Rev 43972
Line 1... Line 1...
1
/* Header describing internals of libintl library.
1
/* Header describing internals of libintl library.
2
   Copyright (C) 1995-1999, 2000-2005 Free Software Foundation, Inc.
2
   Copyright (C) 1995-1999, 2000-2007 Free Software Foundation, Inc.
3
   Written by Ulrich Drepper <drepper@cygnus.com>, 1995.
3
   Written by Ulrich Drepper <drepper@cygnus.com>, 1995.
4
 
4
 
5
   This program is free software; you can redistribute it and/or modify it
5
   This program is free software; you can redistribute it and/or modify it
6
   under the terms of the GNU Library General Public License as published
6
   under the terms of the GNU Library General Public License as published
7
   by the Free Software Foundation; either version 2, or (at your option)
7
   by the Free Software Foundation; either version 2, or (at your option)
Line 28... Line 28...
28
# if HAVE_ICONV
28
# if HAVE_ICONV
29
#  include <iconv.h>
29
#  include <iconv.h>
30
# endif
30
# endif
31
#endif
31
#endif
32
 
32
 
-
 
33
/* Handle multi-threaded applications.  */
-
 
34
#ifdef _LIBC
-
 
35
# include <bits/libc-lock.h>
-
 
36
# define gl_rwlock_define __libc_rwlock_define
-
 
37
#else
-
 
38
# include "lock.h"
-
 
39
#endif
-
 
40
 
33
#ifdef _LIBC
41
#ifdef _LIBC
34
extern char *__gettext (const char *__msgid);
42
extern char *__gettext (const char *__msgid);
35
extern char *__dgettext (const char *__domainname, const char *__msgid);
43
extern char *__dgettext (const char *__domainname, const char *__msgid);
36
extern char *__dcgettext (const char *__domainname, const char *__msgid,
44
extern char *__dcgettext (const char *__domainname, const char *__msgid,
37
			  int __category);
45
			  int __category);
Line 104... Line 112...
104
#ifdef _LIBC
112
#ifdef _LIBC
105
# include <byteswap.h>
113
# include <byteswap.h>
106
# define SWAP(i) bswap_32 (i)
114
# define SWAP(i) bswap_32 (i)
107
#else
115
#else
108
static inline nls_uint32
116
static inline nls_uint32
-
 
117
# ifdef __cplusplus
-
 
118
SWAP (nls_uint32 i)
-
 
119
# else
109
SWAP (i)
120
SWAP (i)
110
     nls_uint32 i;
121
     nls_uint32 i;
-
 
122
# endif
111
{
123
{
112
  return (i << 24) | ((i & 0xff00) << 8) | ((i >> 8) & 0xff00) | (i >> 24);
124
  return (i << 24) | ((i & 0xff00) << 8) | ((i >> 8) & 0xff00) | (i >> 24);
113
}
125
}
114
#endif
126
#endif
115
 
127
 
Line 179... Line 191...
179
  int must_swap_hash_tab;
191
  int must_swap_hash_tab;
180
 
192
 
181
  /* Cache of charset conversions of the translated strings.  */
193
  /* Cache of charset conversions of the translated strings.  */
182
  struct converted_domain *conversions;
194
  struct converted_domain *conversions;
183
  size_t nconversions;
195
  size_t nconversions;
-
 
196
  gl_rwlock_define (, conversions_lock)
184
 
197
 
185
  struct expression *plural;
198
  const struct expression *plural;
186
  unsigned long int nplurals;
199
  unsigned long int nplurals;
187
};
200
};
188
 
201
 
189
/* We want to allocate a string at the end of the struct.  But ISO C
202
/* We want to allocate a string at the end of the struct.  But ISO C
190
   doesn't allow zero sized arrays.  */
203
   doesn't allow zero sized arrays.  */
Line 216... Line 229...
216
#else
229
#else
217
extern LIBINTL_DLL_EXPORTED int _nl_msg_cat_cntr;
230
extern LIBINTL_DLL_EXPORTED int _nl_msg_cat_cntr;
218
#endif
231
#endif
219
 
232
 
220
#ifndef _LIBC
233
#ifndef _LIBC
221
const char *_nl_language_preferences_default (void);
234
extern const char *_nl_language_preferences_default (void);
-
 
235
# define gl_locale_name_canonicalize _nl_locale_name_canonicalize
-
 
236
extern void _nl_locale_name_canonicalize (char *name);
-
 
237
# define gl_locale_name_posix _nl_locale_name_posix
222
const char *_nl_locale_name_posix (int category, const char *categoryname);
238
extern const char *_nl_locale_name_posix (int category,
-
 
239
					  const char *categoryname);
-
 
240
# define gl_locale_name_default _nl_locale_name_default
223
const char *_nl_locale_name_default (void);
241
extern const char *_nl_locale_name_default (void);
-
 
242
# define gl_locale_name _nl_locale_name
224
const char *_nl_locale_name (int category, const char *categoryname);
243
extern const char *_nl_locale_name (int category, const char *categoryname);
225
#endif
244
#endif
226
 
245
 
227
struct loaded_l10nfile *_nl_find_domain (const char *__dirname, char *__locale,
246
struct loaded_l10nfile *_nl_find_domain (const char *__dirname, char *__locale,
228
					 const char *__domainname,
247
					 const char *__domainname,
229
					 struct binding *__domainbinding)
248
					 struct binding *__domainbinding)
Line 243... Line 262...
243
		    struct binding *domainbinding, const char *msgid,
262
		    struct binding *domainbinding, const char *msgid,
244
		    int convert, size_t *lengthp)
263
		    int convert, size_t *lengthp)
245
     internal_function;
264
     internal_function;
246
#endif
265
#endif
247
 
266
 
-
 
267
/* The internal variables in the standalone libintl.a must have different
-
 
268
   names than the internal variables in GNU libc, otherwise programs
-
 
269
   using libintl.a cannot be linked statically.  */
-
 
270
#if !defined _LIBC
-
 
271
# define _nl_default_dirname libintl_nl_default_dirname
-
 
272
# define _nl_domain_bindings libintl_nl_domain_bindings
-
 
273
#endif
-
 
274
 
-
 
275
/* Contains the default location of the message catalogs.  */
-
 
276
extern const char _nl_default_dirname[];
-
 
277
#ifdef _LIBC
-
 
278
libc_hidden_proto (_nl_default_dirname)
-
 
279
#endif
-
 
280
 
-
 
281
/* List with bindings of specific domains.  */
-
 
282
extern struct binding *_nl_domain_bindings;
-
 
283
 
-
 
284
/* The internal variables in the standalone libintl.a must have different
-
 
285
   names than the internal variables in GNU libc, otherwise programs
-
 
286
   using libintl.a cannot be linked statically.  */
-
 
287
#if !defined _LIBC
-
 
288
# define _nl_default_default_domain libintl_nl_default_default_domain
-
 
289
# define _nl_current_default_domain libintl_nl_current_default_domain
-
 
290
#endif
-
 
291
 
-
 
292
/* Name of the default text domain.  */
-
 
293
extern const char _nl_default_default_domain[] attribute_hidden;
-
 
294
 
-
 
295
/* Default text domain in which entries for gettext(3) are to be found.  */
-
 
296
extern const char *_nl_current_default_domain attribute_hidden;
-
 
297
 
248
/* @@ begin of epilog @@ */
298
/* @@ begin of epilog @@ */
249
 
299
 
250
#endif /* gettextP.h  */
300
#endif /* gettextP.h  */