/xbmc/visualizations/Goom/goom2k4-0/gtk-gui-devel/intl/gettext.h

http://github.com/xbmc/xbmc · C++ Header · 105 lines · 46 code · 16 blank · 43 comment · 6 complexity · c46b419b2ebd68930fcb8491fae2bd32 MD5 · raw file

  1. /* Internal header for GNU gettext internationalization functions.
  2. Copyright (C) 1995, 1997 Free Software Foundation, Inc.
  3. This program is free software; you can redistribute it and/or modify
  4. it under the terms of the GNU General Public License as published by
  5. the Free Software Foundation; either version 2, or (at your option)
  6. any later version.
  7. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  10. GNU General Public License for more details.
  11. You should have received a copy of the GNU Library General Public
  12. License along with the GNU C Library; see the file COPYING.LIB. If not,
  13. write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
  14. Boston, MA 02111-1307, USA. */
  15. #ifndef _GETTEXT_H
  16. #define _GETTEXT_H 1
  17. #include <stdio.h>
  18. #if HAVE_LIMITS_H || _LIBC
  19. # include <limits.h>
  20. #endif
  21. /* @@ end of prolog @@ */
  22. /* The magic number of the GNU message catalog format. */
  23. #define _MAGIC 0x950412de
  24. #define _MAGIC_SWAPPED 0xde120495
  25. /* Revision number of the currently used .mo (binary) file format. */
  26. #define MO_REVISION_NUMBER 0
  27. /* The following contortions are an attempt to use the C preprocessor
  28. to determine an unsigned integral type that is 32 bits wide. An
  29. alternative approach is to use autoconf's AC_CHECK_SIZEOF macro, but
  30. doing that would require that the configure script compile and *run*
  31. the resulting executable. Locally running cross-compiled executables
  32. is usually not possible. */
  33. #if __STDC__
  34. # define UINT_MAX_32_BITS 4294967295U
  35. #else
  36. # define UINT_MAX_32_BITS 0xFFFFFFFF
  37. #endif
  38. /* If UINT_MAX isn't defined, assume it's a 32-bit type.
  39. This should be valid for all systems GNU cares about because
  40. that doesn't include 16-bit systems, and only modern systems
  41. (that certainly have <limits.h>) have 64+-bit integral types. */
  42. #ifndef UINT_MAX
  43. # define UINT_MAX UINT_MAX_32_BITS
  44. #endif
  45. #if UINT_MAX == UINT_MAX_32_BITS
  46. typedef unsigned nls_uint32;
  47. #else
  48. # if USHRT_MAX == UINT_MAX_32_BITS
  49. typedef unsigned short nls_uint32;
  50. # else
  51. # if ULONG_MAX == UINT_MAX_32_BITS
  52. typedef unsigned long nls_uint32;
  53. # else
  54. /* The following line is intended to throw an error. Using #error is
  55. not portable enough. */
  56. "Cannot determine unsigned 32-bit data type."
  57. # endif
  58. # endif
  59. #endif
  60. /* Header for binary .mo file format. */
  61. struct mo_file_header
  62. {
  63. /* The magic number. */
  64. nls_uint32 magic;
  65. /* The revision number of the file format. */
  66. nls_uint32 revision;
  67. /* The number of strings pairs. */
  68. nls_uint32 nstrings;
  69. /* Offset of table with start offsets of original strings. */
  70. nls_uint32 orig_tab_offset;
  71. /* Offset of table with start offsets of translation strings. */
  72. nls_uint32 trans_tab_offset;
  73. /* Size of hashing table. */
  74. nls_uint32 hash_tab_size;
  75. /* Offset of first hashing entry. */
  76. nls_uint32 hash_tab_offset;
  77. };
  78. struct string_desc
  79. {
  80. /* Length of addressed string. */
  81. nls_uint32 length;
  82. /* Offset of string in file. */
  83. nls_uint32 offset;
  84. };
  85. /* @@ begin of epilog @@ */
  86. #endif /* gettext.h */