encodings.def 37 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026
  1. /* Copyright (C) 1999-2009 Free Software Foundation, Inc.
  2. This file is part of the GNU LIBICONV Library.
  3. The GNU LIBICONV Library is free software; you can redistribute it
  4. and/or modify it under the terms of the GNU Library General Public
  5. License as published by the Free Software Foundation; either version 2
  6. of the License, or (at your option) any later version.
  7. The GNU LIBICONV Library is distributed in the hope that it will be
  8. useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  10. Library 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 LIBICONV Library; see the file COPYING.LIB.
  13. If not, write to the Free Software Foundation, Inc., 51 Franklin Street,
  14. Fifth Floor, Boston, MA 02110-1301, USA. */
  15. /* The list of all system independent user-visible encodings. */
  16. /* By convention, an encoding named FOOBAR or FOO_BAR or FOO-BAR is defined
  17. in a file named "foobar.h" through the functions foobar_mbtowc and
  18. foobar_wctomb (and possibly foobar_reset). */
  19. /* DEFENCODING(( name, alias1, ..., ),
  20. xxx,
  21. { xxx_mbtowc, xxx_flushwc },
  22. { xxx_wctomb, xxx_reset })
  23. defines an encoding with the given name and aliases. (There is no
  24. difference between a name and an alias. By convention, the name is chosen
  25. as the preferred MIME name or the standard name.)
  26. All names and aliases must be in ASCII. Case is not significant, but
  27. for the "cs*" aliases mixed case is preferred, otherwise UPPERCASE is
  28. preferred. For all names and aliases, note where it comes from.
  29. xxx is the name as used in the C code (lowercase).
  30. */
  31. DEFENCODING(( "US-ASCII", /* IANA */
  32. "ASCII", /* IANA, JDK 1.1 */
  33. "ISO646-US", /* IANA */
  34. "ISO_646.IRV:1991", /* IANA */
  35. "ISO-IR-6", /* IANA */
  36. "ANSI_X3.4-1968", /* IANA */
  37. "ANSI_X3.4-1986", /* IANA */
  38. "CP367", /* IANA */
  39. "IBM367", /* IANA */
  40. "US", /* IANA */
  41. "csASCII", /* IANA */
  42. /*"ISO646.1991-IRV", X11R6.4 */
  43. ),
  44. ascii,
  45. { ascii_mbtowc, NULL }, { ascii_wctomb, NULL })
  46. #ifdef USE_SOLARIS_ALIASES
  47. DEFALIAS( "646", /* Solaris */
  48. ascii)
  49. #endif
  50. /* General multi-byte encodings */
  51. DEFENCODING(( "UTF-8", /* IANA, RFC 2279 */
  52. /*"UTF8", JDK 1.1 */
  53. /*"CP65001", Windows */
  54. ),
  55. utf8,
  56. { utf8_mbtowc, NULL }, { utf8_wctomb, NULL })
  57. #ifdef USE_HPUX_ALIASES
  58. DEFALIAS( "UTF8", /* HP-UX */
  59. utf8)
  60. #endif
  61. DEFENCODING(( "UCS-2", /* glibc */
  62. "ISO-10646-UCS-2", /* IANA */
  63. "csUnicode", /* IANA */
  64. ),
  65. ucs2,
  66. { ucs2_mbtowc, NULL }, { ucs2_wctomb, NULL })
  67. DEFENCODING(( "UCS-2BE", /* glibc */
  68. "UNICODEBIG", /* glibc */
  69. "UNICODE-1-1", /* IANA */
  70. "csUnicode11", /* IANA */
  71. /*"CP1201", Windows */
  72. ),
  73. ucs2be,
  74. { ucs2be_mbtowc, NULL }, { ucs2be_wctomb, NULL })
  75. DEFENCODING(( "UCS-2LE", /* glibc */
  76. "UNICODELITTLE", /* glibc */
  77. /*"CP1200", Windows */
  78. ),
  79. ucs2le,
  80. { ucs2le_mbtowc, NULL }, { ucs2le_wctomb, NULL })
  81. DEFENCODING(( "UCS-4", /* glibc */
  82. "ISO-10646-UCS-4", /* IANA */
  83. "csUCS4", /* IANA */
  84. ),
  85. ucs4,
  86. { ucs4_mbtowc, NULL }, { ucs4_wctomb, NULL })
  87. DEFENCODING(( "UCS-4BE", /* glibc */
  88. /*"CP12001", Windows */
  89. ),
  90. ucs4be,
  91. { ucs4be_mbtowc, NULL }, { ucs4be_wctomb, NULL })
  92. DEFENCODING(( "UCS-4LE", /* glibc */
  93. /*"CP12000", Windows */
  94. ),
  95. ucs4le,
  96. { ucs4le_mbtowc, NULL }, { ucs4le_wctomb, NULL })
  97. DEFENCODING(( "UTF-16", /* IANA, RFC 2781 */
  98. ),
  99. utf16,
  100. { utf16_mbtowc, NULL }, { utf16_wctomb, NULL })
  101. DEFENCODING(( "UTF-16BE", /* IANA, RFC 2781 */
  102. ),
  103. utf16be,
  104. { utf16be_mbtowc, NULL }, { utf16be_wctomb, NULL })
  105. DEFENCODING(( "UTF-16LE", /* IANA, RFC 2781 */
  106. ),
  107. utf16le,
  108. { utf16le_mbtowc, NULL }, { utf16le_wctomb, NULL })
  109. DEFENCODING(( "UTF-32", /* IANA, Unicode 3.1 */
  110. ),
  111. utf32,
  112. { utf32_mbtowc, NULL }, { utf32_wctomb, NULL })
  113. DEFENCODING(( "UTF-32BE", /* IANA, Unicode 3.1 */
  114. ),
  115. utf32be,
  116. { utf32be_mbtowc, NULL }, { utf32be_wctomb, NULL })
  117. DEFENCODING(( "UTF-32LE", /* IANA, Unicode 3.1 */
  118. ),
  119. utf32le,
  120. { utf32le_mbtowc, NULL }, { utf32le_wctomb, NULL })
  121. DEFENCODING(( "UTF-7", /* IANA, RFC 2152 */
  122. "UNICODE-1-1-UTF-7", /* IANA, RFC 1642 */
  123. "csUnicode11UTF7", /* IANA */
  124. /*"CP65000", Windows */
  125. ),
  126. utf7,
  127. { utf7_mbtowc, NULL }, { utf7_wctomb, utf7_reset })
  128. DEFENCODING(( "UCS-2-INTERNAL", /* libiconv */
  129. ),
  130. ucs2internal,
  131. { ucs2internal_mbtowc, NULL }, { ucs2internal_wctomb, NULL })
  132. DEFENCODING(( "UCS-2-SWAPPED", /* libiconv */
  133. ),
  134. ucs2swapped,
  135. { ucs2swapped_mbtowc, NULL }, { ucs2swapped_wctomb, NULL })
  136. DEFENCODING(( "UCS-4-INTERNAL", /* libiconv */
  137. ),
  138. ucs4internal,
  139. { ucs4internal_mbtowc, NULL },{ ucs4internal_wctomb, NULL })
  140. DEFENCODING(( "UCS-4-SWAPPED", /* libiconv */
  141. ),
  142. ucs4swapped,
  143. { ucs4swapped_mbtowc, NULL }, { ucs4swapped_wctomb, NULL })
  144. DEFENCODING(( "C99",
  145. ),
  146. c99,
  147. { c99_mbtowc, NULL }, { c99_wctomb, NULL })
  148. DEFENCODING(( "JAVA",
  149. ),
  150. java,
  151. { java_mbtowc, NULL }, { java_wctomb, NULL })
  152. /* Standard 8-bit encodings */
  153. DEFENCODING(( "ISO-8859-1", /* IANA */
  154. "ISO_8859-1", /* IANA */
  155. "ISO_8859-1:1987", /* IANA */
  156. "ISO-IR-100", /* IANA */
  157. "CP819", /* IANA */
  158. "IBM819", /* IANA */
  159. "LATIN1", /* IANA */
  160. "L1", /* IANA */
  161. "csISOLatin1", /* IANA */
  162. "ISO8859-1", /* X11R6.4, glibc, FreeBSD, AIX, IRIX, OSF/1, Solaris */
  163. /*"ISO8859_1", JDK 1.1 */
  164. /*"CP28591", Windows */
  165. ),
  166. iso8859_1,
  167. { iso8859_1_mbtowc, NULL }, { iso8859_1_wctomb, NULL })
  168. #ifdef USE_HPUX_ALIASES
  169. DEFALIAS( "ISO88591", /* HP-UX */
  170. iso8859_1)
  171. #endif
  172. DEFENCODING(( "ISO-8859-2", /* IANA */
  173. "ISO_8859-2", /* IANA */
  174. "ISO_8859-2:1987", /* IANA */
  175. "ISO-IR-101", /* IANA */
  176. "LATIN2", /* IANA */
  177. "L2", /* IANA */
  178. "csISOLatin2", /* IANA */
  179. "ISO8859-2", /* X11R6.4, glibc, FreeBSD, AIX, IRIX, OSF/1, Solaris */
  180. /*"ISO8859_2", JDK 1.1 */
  181. /*"CP28592", Windows */
  182. ),
  183. iso8859_2,
  184. { iso8859_2_mbtowc, NULL }, { iso8859_2_wctomb, NULL })
  185. #ifdef USE_HPUX_ALIASES
  186. DEFALIAS( "ISO88592", /* HP-UX */
  187. iso8859_2)
  188. #endif
  189. DEFENCODING(( "ISO-8859-3", /* IANA */
  190. "ISO_8859-3", /* IANA */
  191. "ISO_8859-3:1988", /* IANA */
  192. "ISO-IR-109", /* IANA */
  193. "LATIN3", /* IANA */
  194. "L3", /* IANA */
  195. "csISOLatin3", /* IANA */
  196. "ISO8859-3", /* X11R6.4, glibc, FreeBSD, Solaris */
  197. /*"ISO8859_3", JDK 1.1 */
  198. /*"CP28593", Windows */
  199. ),
  200. iso8859_3,
  201. { iso8859_3_mbtowc, NULL }, { iso8859_3_wctomb, NULL })
  202. DEFENCODING(( "ISO-8859-4", /* IANA */
  203. "ISO_8859-4", /* IANA */
  204. "ISO_8859-4:1988", /* IANA */
  205. "ISO-IR-110", /* IANA */
  206. "LATIN4", /* IANA */
  207. "L4", /* IANA */
  208. "csISOLatin4", /* IANA */
  209. "ISO8859-4", /* X11R6.4, glibc, FreeBSD, OSF/1, Solaris */
  210. /*"ISO8859_4", JDK 1.1 */
  211. /*"CP28594", Windows */
  212. ),
  213. iso8859_4,
  214. { iso8859_4_mbtowc, NULL }, { iso8859_4_wctomb, NULL })
  215. DEFENCODING(( "ISO-8859-5", /* IANA */
  216. "ISO_8859-5", /* IANA */
  217. "ISO_8859-5:1988", /* IANA */
  218. "ISO-IR-144", /* IANA */
  219. "CYRILLIC", /* IANA */
  220. "csISOLatinCyrillic", /* IANA */
  221. "ISO8859-5", /* X11R6.4, glibc, FreeBSD, AIX, IRIX, OSF/1, Solaris */
  222. /*"ISO8859_5", JDK 1.1 */
  223. /*"CP28595", Windows */
  224. ),
  225. iso8859_5,
  226. { iso8859_5_mbtowc, NULL }, { iso8859_5_wctomb, NULL })
  227. #ifdef USE_HPUX_ALIASES
  228. DEFALIAS( "ISO88595", /* HP-UX */
  229. iso8859_5)
  230. #endif
  231. DEFENCODING(( "ISO-8859-6", /* IANA */
  232. "ISO_8859-6", /* IANA */
  233. "ISO_8859-6:1987", /* IANA */
  234. "ISO-IR-127", /* IANA */
  235. "ECMA-114", /* IANA */
  236. "ASMO-708", /* IANA */
  237. "ARABIC", /* IANA */
  238. "csISOLatinArabic", /* IANA */
  239. "ISO8859-6", /* X11R6.4, glibc, FreeBSD, AIX, Solaris */
  240. /*"ISO8859_6", JDK 1.1 */
  241. /*"CP28596", Windows */
  242. ),
  243. iso8859_6,
  244. { iso8859_6_mbtowc, NULL }, { iso8859_6_wctomb, NULL })
  245. #ifdef USE_HPUX_ALIASES
  246. DEFALIAS( "ISO88596", /* HP-UX */
  247. iso8859_6)
  248. #endif
  249. DEFENCODING(( "ISO-8859-7", /* IANA, RFC 1947 */
  250. "ISO_8859-7", /* IANA */
  251. "ISO_8859-7:1987", /* IANA */
  252. "ISO_8859-7:2003",
  253. "ISO-IR-126", /* IANA */
  254. "ECMA-118", /* IANA */
  255. "ELOT_928", /* IANA */
  256. "GREEK8", /* IANA */
  257. "GREEK", /* IANA */
  258. "csISOLatinGreek", /* IANA */
  259. "ISO8859-7", /* X11R6.4, glibc, FreeBSD, AIX, IRIX, OSF/1, Solaris */
  260. /*"ISO8859_7", JDK 1.1 */
  261. /*"CP28597", Windows */
  262. ),
  263. iso8859_7,
  264. { iso8859_7_mbtowc, NULL }, { iso8859_7_wctomb, NULL })
  265. #ifdef USE_HPUX_ALIASES
  266. DEFALIAS( "ISO88597", /* HP-UX */
  267. iso8859_7)
  268. #endif
  269. DEFENCODING(( "ISO-8859-8", /* IANA */
  270. "ISO_8859-8", /* IANA */
  271. "ISO_8859-8:1988", /* IANA */
  272. "ISO-IR-138", /* IANA */
  273. "HEBREW", /* IANA */
  274. "csISOLatinHebrew", /* IANA */
  275. "ISO8859-8", /* X11R6.4, glibc, FreeBSD, AIX, OSF/1, Solaris */
  276. /*"ISO8859_8", JDK 1.1 */
  277. /*"CP28598", Windows */
  278. /*"CP38598", Windows */
  279. ),
  280. iso8859_8,
  281. { iso8859_8_mbtowc, NULL }, { iso8859_8_wctomb, NULL })
  282. #ifdef USE_HPUX_ALIASES
  283. DEFALIAS( "ISO88598", /* HP-UX */
  284. iso8859_8)
  285. #endif
  286. DEFENCODING(( "ISO-8859-9", /* IANA */
  287. "ISO_8859-9", /* IANA */
  288. "ISO_8859-9:1989", /* IANA */
  289. "ISO-IR-148", /* IANA */
  290. "LATIN5", /* IANA */
  291. "L5", /* IANA */
  292. "csISOLatin5", /* IANA */
  293. "ISO8859-9", /* X11R6.4, glibc, FreeBSD, AIX, IRIX, OSF/1, Solaris */
  294. /*"ISO8859_9", JDK 1.1 */
  295. /*"CP28599", Windows */
  296. ),
  297. iso8859_9,
  298. { iso8859_9_mbtowc, NULL }, { iso8859_9_wctomb, NULL })
  299. #ifdef USE_HPUX_ALIASES
  300. DEFALIAS( "ISO88599", /* HP-UX */
  301. iso8859_9)
  302. #endif
  303. DEFENCODING(( "ISO-8859-10", /* IANA */
  304. "ISO_8859-10",
  305. "ISO_8859-10:1992", /* IANA */
  306. "ISO-IR-157", /* IANA */
  307. "LATIN6", /* IANA */
  308. "L6", /* IANA */
  309. "csISOLatin6", /* IANA */
  310. "ISO8859-10", /* X11R6.4, glibc, FreeBSD */
  311. ),
  312. iso8859_10,
  313. { iso8859_10_mbtowc, NULL }, { iso8859_10_wctomb, NULL })
  314. DEFENCODING(( "ISO-8859-11", /* glibc */
  315. "ISO_8859-11",
  316. "ISO8859-11", /* X11R6.7, glibc */
  317. ),
  318. iso8859_11,
  319. { iso8859_11_mbtowc, NULL }, { iso8859_11_wctomb, NULL })
  320. DEFENCODING(( "ISO-8859-13", /* IANA, glibc */
  321. "ISO_8859-13",
  322. "ISO-IR-179", /* glibc */
  323. "LATIN7", /* glibc */
  324. "L7", /* glibc */
  325. "ISO8859-13", /* glibc, FreeBSD */
  326. ),
  327. iso8859_13,
  328. { iso8859_13_mbtowc, NULL }, { iso8859_13_wctomb, NULL })
  329. #ifdef USE_AIX_ALIASES
  330. DEFALIAS( "IBM-921", /* AIX */
  331. iso8859_13)
  332. #endif
  333. DEFENCODING(( "ISO-8859-14", /* IANA, glibc */
  334. "ISO_8859-14", /* IANA */
  335. "ISO_8859-14:1998", /* IANA, glibc */
  336. "ISO-IR-199", /* IANA */
  337. "LATIN8", /* IANA, glibc */
  338. "L8", /* IANA, glibc */
  339. "ISO-CELTIC", /* IANA */
  340. "ISO8859-14", /* glibc, FreeBSD */
  341. ),
  342. iso8859_14,
  343. { iso8859_14_mbtowc, NULL }, { iso8859_14_wctomb, NULL })
  344. DEFENCODING(( "ISO-8859-15", /* IANA, glibc */
  345. "ISO_8859-15", /* IANA */
  346. "ISO_8859-15:1998", /* glibc */
  347. "ISO-IR-203",
  348. "LATIN-9", /* IANA */
  349. "ISO8859-15", /* glibc, FreeBSD, AIX, OSF/1, Solaris */
  350. /*"CP28605", Windows */
  351. ),
  352. iso8859_15,
  353. { iso8859_15_mbtowc, NULL }, { iso8859_15_wctomb, NULL })
  354. #ifdef USE_HPUX_ALIASES
  355. DEFALIAS( "ISO885915", /* HP-UX */
  356. iso8859_15)
  357. #endif
  358. DEFENCODING(( "ISO-8859-16", /* IANA */
  359. "ISO_8859-16", /* IANA */
  360. "ISO_8859-16:2001", /* IANA */
  361. "ISO-IR-226", /* IANA */
  362. "LATIN10", /* IANA */
  363. "L10", /* IANA */
  364. "ISO8859-16", /* glibc, FreeBSD */
  365. ),
  366. iso8859_16,
  367. { iso8859_16_mbtowc, NULL }, { iso8859_16_wctomb, NULL })
  368. DEFENCODING(( "KOI8-R", /* IANA, RFC 1489, X11R6.4, JDK 1.1 */
  369. "csKOI8R", /* IANA */
  370. /*"CP20866", Windows */
  371. ),
  372. koi8_r,
  373. { koi8_r_mbtowc, NULL }, { koi8_r_wctomb, NULL })
  374. DEFENCODING(( "KOI8-U", /* IANA, RFC 2319 */
  375. ),
  376. koi8_u,
  377. { koi8_u_mbtowc, NULL }, { koi8_u_wctomb, NULL })
  378. DEFENCODING(( "KOI8-RU",
  379. ),
  380. koi8_ru,
  381. { koi8_ru_mbtowc, NULL }, { koi8_ru_wctomb, NULL })
  382. /* Windows 8-bit encodings */
  383. DEFENCODING(( "CP1250", /* JDK 1.1 */
  384. "WINDOWS-1250", /* IANA */
  385. "MS-EE",
  386. ),
  387. cp1250,
  388. { cp1250_mbtowc, NULL }, { cp1250_wctomb, NULL })
  389. DEFENCODING(( "CP1251", /* JDK 1.1 */
  390. "WINDOWS-1251", /* IANA */
  391. "MS-CYRL",
  392. ),
  393. cp1251,
  394. { cp1251_mbtowc, NULL }, { cp1251_wctomb, NULL })
  395. #ifdef USE_SOLARIS_ALIASES
  396. DEFALIAS( "ANSI-1251", /* Solaris */
  397. cp1251)
  398. #endif
  399. DEFENCODING(( "CP1252", /* JDK 1.1 */
  400. "WINDOWS-1252", /* IANA */
  401. "MS-ANSI",
  402. ),
  403. cp1252,
  404. { cp1252_mbtowc, NULL }, { cp1252_wctomb, NULL })
  405. #ifdef USE_AIX_ALIASES
  406. DEFALIAS( "IBM-1252", /* AIX */
  407. cp1252)
  408. #endif
  409. DEFENCODING(( "CP1253", /* JDK 1.1 */
  410. "WINDOWS-1253", /* IANA */
  411. "MS-GREEK",
  412. ),
  413. cp1253,
  414. { cp1253_mbtowc, NULL }, { cp1253_wctomb, NULL })
  415. DEFENCODING(( "CP1254", /* JDK 1.1 */
  416. "WINDOWS-1254", /* IANA */
  417. "MS-TURK",
  418. ),
  419. cp1254,
  420. { cp1254_mbtowc, NULL }, { cp1254_wctomb, NULL })
  421. DEFENCODING(( "CP1255", /* JDK 1.1 */
  422. "WINDOWS-1255", /* IANA */
  423. "MS-HEBR",
  424. ),
  425. cp1255,
  426. { cp1255_mbtowc, cp1255_flushwc }, { cp1255_wctomb, NULL })
  427. DEFENCODING(( "CP1256", /* JDK 1.1 */
  428. "WINDOWS-1256", /* IANA */
  429. "MS-ARAB",
  430. ),
  431. cp1256,
  432. { cp1256_mbtowc, NULL }, { cp1256_wctomb, NULL })
  433. DEFENCODING(( "CP1257", /* JDK 1.1 */
  434. "WINDOWS-1257", /* IANA */
  435. "WINBALTRIM",
  436. ),
  437. cp1257,
  438. { cp1257_mbtowc, NULL }, { cp1257_wctomb, NULL })
  439. DEFENCODING(( "CP1258", /* JDK 1.1 */
  440. "WINDOWS-1258", /* IANA */
  441. ),
  442. cp1258,
  443. { cp1258_mbtowc, cp1258_flushwc }, { cp1258_wctomb, NULL })
  444. /* DOS 8-bit encodings */
  445. DEFENCODING(( "CP850", /* IANA, JDK 1.1 */
  446. "IBM850", /* IANA */
  447. "850", /* IANA */
  448. "csPC850Multilingual", /* IANA */
  449. ),
  450. cp850,
  451. { cp850_mbtowc, NULL }, { cp850_wctomb, NULL })
  452. #ifdef USE_AIX_ALIASES
  453. DEFALIAS( "IBM-850", /* AIX */
  454. cp850)
  455. #endif
  456. DEFENCODING(( "CP862", /* IANA, JDK 1.1 */
  457. "IBM862", /* IANA */
  458. "862", /* IANA */
  459. "csPC862LatinHebrew", /* IANA */
  460. ),
  461. cp862,
  462. { cp862_mbtowc, NULL }, { cp862_wctomb, NULL })
  463. DEFENCODING(( "CP866", /* IANA, JDK 1.1 */
  464. "IBM866", /* IANA */
  465. "866", /* IANA */
  466. "csIBM866", /* IANA */
  467. ),
  468. cp866,
  469. { cp866_mbtowc, NULL }, { cp866_wctomb, NULL })
  470. DEFENCODING(( "CP1131", /* FreeBSD, MacOS X */
  471. ),
  472. cp1131,
  473. { cp1131_mbtowc, NULL }, { cp1131_wctomb, NULL })
  474. #ifdef USE_AIX_ALIASES
  475. DEFALIAS( "IBM-1131", /* AIX */
  476. cp1131)
  477. #endif
  478. /* Macintosh 8-bit encodings */
  479. DEFENCODING(( "MacRoman", /* JDK 1.1 */
  480. /* This is the best table for MACINTOSH. The ones */
  481. /* in glibc and FreeBSD-iconv are bad quality. */
  482. "MACINTOSH", /* IANA */
  483. "MAC", /* IANA */
  484. "csMacintosh", /* IANA */
  485. /*"CP10000", Windows */
  486. ),
  487. mac_roman,
  488. { mac_roman_mbtowc, NULL }, { mac_roman_wctomb, NULL })
  489. DEFENCODING(( "MacCentralEurope", /* JDK 1.1 */
  490. /*"CP10029", Windows */
  491. ),
  492. mac_centraleurope,
  493. { mac_centraleurope_mbtowc, NULL }, { mac_centraleurope_wctomb, NULL })
  494. DEFENCODING(( "MacIceland", /* JDK 1.1 */
  495. /*"CP10079", Windows */
  496. ),
  497. mac_iceland,
  498. { mac_iceland_mbtowc, NULL }, { mac_iceland_wctomb, NULL })
  499. DEFENCODING(( "MacCroatian", /* JDK 1.1 */
  500. /*"CP10082", Windows */
  501. ),
  502. mac_croatian,
  503. { mac_croatian_mbtowc, NULL }, { mac_croatian_wctomb, NULL })
  504. DEFENCODING(( "MacRomania", /* JDK 1.1 */
  505. /*"CP10010", Windows */
  506. ),
  507. mac_romania,
  508. { mac_romania_mbtowc, NULL }, { mac_romania_wctomb, NULL })
  509. DEFENCODING(( "MacCyrillic", /* JDK 1.1 */
  510. /*"CP10007", Windows */
  511. ),
  512. mac_cyrillic,
  513. { mac_cyrillic_mbtowc, NULL }, { mac_cyrillic_wctomb, NULL })
  514. DEFENCODING(( "MacUkraine", /* JDK 1.1 */
  515. /*"CP10017", Windows */
  516. ),
  517. mac_ukraine,
  518. { mac_ukraine_mbtowc, NULL }, { mac_ukraine_wctomb, NULL })
  519. DEFENCODING(( "MacGreek", /* JDK 1.1 */
  520. /*"CP10006", Windows */
  521. ),
  522. mac_greek,
  523. { mac_greek_mbtowc, NULL }, { mac_greek_wctomb, NULL })
  524. DEFENCODING(( "MacTurkish", /* JDK 1.1 */
  525. /*"CP10081", Windows */
  526. ),
  527. mac_turkish,
  528. { mac_turkish_mbtowc, NULL }, { mac_turkish_wctomb, NULL })
  529. DEFENCODING(( "MacHebrew", /* JDK 1.1 */
  530. /*"CP10005", Windows */
  531. ),
  532. mac_hebrew,
  533. { mac_hebrew_mbtowc, NULL }, { mac_hebrew_wctomb, NULL })
  534. DEFENCODING(( "MacArabic", /* JDK 1.1 */
  535. /*"CP10004", Windows */
  536. ),
  537. mac_arabic,
  538. { mac_arabic_mbtowc, NULL }, { mac_arabic_wctomb, NULL })
  539. DEFENCODING(( "MacThai", /* JDK 1.1 */
  540. /*"CP10021", Windows */
  541. ),
  542. mac_thai,
  543. { mac_thai_mbtowc, NULL }, { mac_thai_wctomb, NULL })
  544. /* Other platform specific 8-bit encodings */
  545. DEFENCODING(( "HP-ROMAN8", /* IANA, X11R6.4 */
  546. "ROMAN8", /* IANA */
  547. "R8", /* IANA */
  548. "csHPRoman8", /* IANA */
  549. ),
  550. hp_roman8,
  551. { hp_roman8_mbtowc, NULL }, { hp_roman8_wctomb, NULL })
  552. DEFENCODING(( "NEXTSTEP",
  553. ),
  554. nextstep,
  555. { nextstep_mbtowc, NULL }, { nextstep_wctomb, NULL })
  556. /* Regional 8-bit encodings used for a single language */
  557. DEFENCODING(( "ARMSCII-8",
  558. ),
  559. armscii_8,
  560. { armscii_8_mbtowc, NULL }, { armscii_8_wctomb, NULL })
  561. DEFENCODING(( "GEORGIAN-ACADEMY",
  562. ),
  563. georgian_academy,
  564. { georgian_academy_mbtowc, NULL }, { georgian_academy_wctomb, NULL })
  565. DEFENCODING(( "GEORGIAN-PS",
  566. ),
  567. georgian_ps,
  568. { georgian_ps_mbtowc, NULL }, { georgian_ps_wctomb, NULL })
  569. DEFENCODING(( "KOI8-T",
  570. ),
  571. koi8_t,
  572. { koi8_t_mbtowc, NULL }, { koi8_t_wctomb, NULL })
  573. DEFENCODING(( "PT154", /* IANA, glibc */
  574. "PTCP154", /* IANA */
  575. "CP154", /* IANA */
  576. "CYRILLIC-ASIAN", /* IANA */
  577. "csPTCP154", /* IANA */
  578. ),
  579. pt154,
  580. { pt154_mbtowc, NULL }, { pt154_wctomb, NULL })
  581. DEFENCODING(( "RK1048", /* IANA, glibc */
  582. "STRK1048-2002", /* IANA */
  583. "KZ-1048", /* IANA */
  584. "csKZ1048", /* IANA */
  585. ),
  586. rk1048,
  587. { rk1048_mbtowc, NULL }, { rk1048_wctomb, NULL })
  588. DEFENCODING(( "MULELAO-1",
  589. ),
  590. mulelao,
  591. { mulelao_mbtowc, NULL }, { mulelao_wctomb, NULL })
  592. DEFENCODING(( "CP1133",
  593. "IBM-CP1133",
  594. ),
  595. cp1133,
  596. { cp1133_mbtowc, NULL }, { cp1133_wctomb, NULL })
  597. DEFENCODING(( "TIS-620", /* IANA */
  598. "TIS620", /* glibc, HP-UX */
  599. "TIS620-0", /* glibc */
  600. "TIS620.2529-1", /* glibc */
  601. "TIS620.2533-0", /* glibc */
  602. "TIS620.2533-1",
  603. "ISO-IR-166", /* glibc */
  604. ),
  605. tis620,
  606. { tis620_mbtowc, NULL }, { tis620_wctomb, NULL })
  607. #ifdef USE_OSF1_ALIASES
  608. DEFALIAS( "TACTIS", /* OSF/1 */
  609. tis620)
  610. #endif
  611. #ifdef USE_SOLARIS_ALIASES
  612. DEFALIAS( "TIS620.2533", /* Solaris */
  613. tis620)
  614. #endif
  615. DEFENCODING(( "CP874", /* JDK 1.1 */
  616. "WINDOWS-874",
  617. ),
  618. cp874,
  619. { cp874_mbtowc, NULL }, { cp874_wctomb, NULL })
  620. DEFENCODING(( "VISCII", /* IANA, RFC 1456 */
  621. "VISCII1.1-1",
  622. "csVISCII", /* IANA */
  623. ),
  624. viscii,
  625. { viscii_mbtowc, NULL }, { viscii_wctomb, NULL })
  626. DEFENCODING(( "TCVN",
  627. "TCVN-5712",
  628. "TCVN5712-1",
  629. "TCVN5712-1:1993",
  630. ),
  631. tcvn,
  632. { tcvn_mbtowc, tcvn_flushwc }, { tcvn_wctomb, NULL })
  633. /* CJK character sets (not documented) */
  634. #ifndef ARCADIA_ICONV_NOCJK
  635. DEFENCODING(( "JIS_C6220-1969-RO", /* IANA */
  636. "ISO646-JP", /* IANA */
  637. "ISO-IR-14", /* IANA */
  638. "JP", /* IANA */
  639. "csISO14JISC6220ro", /* IANA */
  640. ),
  641. iso646_jp,
  642. { iso646_jp_mbtowc, NULL }, { iso646_jp_wctomb, NULL })
  643. DEFENCODING(( "JIS_X0201", /* IANA */
  644. "JISX0201-1976",
  645. "X0201", /* IANA */
  646. "csHalfWidthKatakana", /* IANA */
  647. /*"JISX0201.1976-0", X11R6.4 */
  648. /*"JIS0201", JDK 1.1 */
  649. ),
  650. jisx0201,
  651. { jisx0201_mbtowc, NULL }, { jisx0201_wctomb, NULL })
  652. DEFENCODING(( "JIS_X0208",
  653. "JIS_X0208-1983", /* IANA */
  654. "JIS_X0208-1990",
  655. "JIS0208",
  656. "X0208", /* IANA */
  657. "ISO-IR-87", /* IANA */
  658. "JIS_C6226-1983", /* IANA */
  659. "csISO87JISX0208", /* IANA */
  660. /*"JISX0208.1983-0", X11R6.4 */
  661. /*"JISX0208.1990-0", X11R6.4 */
  662. /*"JIS0208", JDK 1.1 */
  663. ),
  664. jisx0208,
  665. { jisx0208_mbtowc, NULL }, { jisx0208_wctomb, NULL })
  666. DEFENCODING(( "JIS_X0212",
  667. "JIS_X0212.1990-0",
  668. "JIS_X0212-1990", /* IANA */
  669. "X0212", /* IANA */
  670. "ISO-IR-159", /* IANA */
  671. "csISO159JISX02121990", /* IANA */
  672. /*"JISX0212.1990-0", X11R6.4 */
  673. /*"JIS0212", JDK 1.1 */
  674. ),
  675. jisx0212,
  676. { jisx0212_mbtowc, NULL }, { jisx0212_wctomb, NULL })
  677. DEFENCODING(( "GB_1988-80", /* IANA */
  678. "ISO646-CN", /* IANA */
  679. "ISO-IR-57", /* IANA */
  680. "CN", /* IANA */
  681. "csISO57GB1988", /* IANA */
  682. ),
  683. iso646_cn,
  684. { iso646_cn_mbtowc, NULL }, { iso646_cn_wctomb, NULL })
  685. DEFENCODING(( "GB_2312-80", /* IANA */
  686. "ISO-IR-58", /* IANA */
  687. "csISO58GB231280", /* IANA */
  688. "CHINESE", /* IANA */
  689. /*"GB2312.1980-0", X11R6.4 */
  690. ),
  691. gb2312,
  692. { gb2312_mbtowc, NULL }, { gb2312_wctomb, NULL })
  693. DEFENCODING(( "ISO-IR-165",
  694. "CN-GB-ISOIR165", /* RFC 1922 */
  695. ),
  696. isoir165,
  697. { isoir165_mbtowc, NULL }, { isoir165_wctomb, NULL })
  698. DEFENCODING(( "KSC_5601", /* IANA */
  699. "KS_C_5601-1987", /* IANA */
  700. "KS_C_5601-1989", /* IANA */
  701. "ISO-IR-149", /* IANA */
  702. "csKSC56011987", /* IANA */
  703. "KOREAN", /* IANA */
  704. /*"KSC5601.1987-0", X11R6.4 */
  705. /*"KSX1001:1992", Ken Lunde */
  706. ),
  707. ksc5601,
  708. { ksc5601_mbtowc, NULL }, { ksc5601_wctomb, NULL })
  709. /* CJK encodings */
  710. DEFENCODING(( "EUC-JP", /* IANA */
  711. "EUCJP", /* glibc, HP-UX, IRIX, OSF/1, Solaris */
  712. "Extended_UNIX_Code_Packed_Format_for_Japanese", /* IANA */
  713. "csEUCPkdFmtJapanese", /* IANA */
  714. /*"EUC_JP", JDK 1.1 */
  715. /*"CP51932", Windows */
  716. ),
  717. euc_jp,
  718. { euc_jp_mbtowc, NULL }, { euc_jp_wctomb, NULL })
  719. #ifdef USE_AIX_ALIASES
  720. DEFALIAS( "IBM-EUCJP", /* AIX */
  721. euc_jp)
  722. #endif
  723. #ifdef USE_OSF1_ALIASES
  724. DEFALIAS( "SDECKANJI", /* OSF/1 */
  725. euc_jp)
  726. #endif
  727. DEFENCODING(( "SHIFT_JIS", /* IANA */
  728. "SHIFT-JIS", /* glibc */
  729. "SJIS", /* JDK 1.1, HP-UX, OSF/1 */
  730. "MS_KANJI", /* IANA */
  731. "csShiftJIS", /* IANA */
  732. ),
  733. sjis,
  734. { sjis_mbtowc, NULL }, { sjis_wctomb, NULL })
  735. #ifdef USE_SOLARIS_ALIASES
  736. DEFALIAS( "PCK", /* Solaris */
  737. sjis)
  738. #endif
  739. DEFENCODING(( "CP932", /* glibc */
  740. ),
  741. cp932,
  742. { cp932_mbtowc, NULL }, { cp932_wctomb, NULL })
  743. #ifdef USE_AIX_ALIASES
  744. DEFALIAS( "IBM-932", /* AIX */
  745. cp932)
  746. #endif
  747. DEFENCODING(( "ISO-2022-JP", /* IANA, RFC 1468 */
  748. "csISO2022JP", /* IANA */
  749. /*"ISO2022JP", JDK 1.1 */
  750. ),
  751. iso2022_jp,
  752. { iso2022_jp_mbtowc, NULL }, { iso2022_jp_wctomb, iso2022_jp_reset })
  753. DEFENCODING(( "ISO-2022-JP-1", /* RFC 2237 */
  754. ),
  755. iso2022_jp1,
  756. { iso2022_jp1_mbtowc, NULL }, { iso2022_jp1_wctomb, iso2022_jp1_reset })
  757. DEFENCODING(( "ISO-2022-JP-2", /* IANA, RFC 1554 */
  758. "csISO2022JP2", /* IANA */
  759. ),
  760. iso2022_jp2,
  761. { iso2022_jp2_mbtowc, NULL }, { iso2022_jp2_wctomb, iso2022_jp2_reset })
  762. DEFENCODING(( "EUC-CN", /* glibc */
  763. "EUCCN", /* glibc, IRIX */
  764. "GB2312", /* IANA */
  765. "CN-GB", /* RFC 1922 */
  766. "csGB2312", /* IANA */
  767. /*"EUC_CN", JDK 1.1 */
  768. /*"CP51936", Windows */
  769. ),
  770. euc_cn,
  771. { euc_cn_mbtowc, NULL }, { euc_cn_wctomb, NULL })
  772. #ifdef USE_AIX_ALIASES
  773. DEFALIAS( "IBM-EUCCN", /* AIX */
  774. euc_cn)
  775. #endif
  776. #ifdef USE_HPUX_ALIASES
  777. DEFALIAS( "HP15CN", /* HP-UX */
  778. euc_cn)
  779. #endif
  780. #ifdef USE_OSF1_ALIASES
  781. DEFALIAS( "DECHANZI", /* OSF/1 */
  782. euc_cn)
  783. #endif
  784. DEFENCODING(( "GBK", /* IANA, JDK 1.1 */
  785. ),
  786. ces_gbk,
  787. { ces_gbk_mbtowc, NULL }, { ces_gbk_wctomb, NULL })
  788. DEFENCODING(( "CP936", /* IANA */
  789. "MS936", /* IANA */
  790. "WINDOWS-936", /* IANA */
  791. ),
  792. cp936,
  793. { cp936_mbtowc, NULL }, { cp936_wctomb, NULL })
  794. DEFENCODING(( "GB18030", /* IANA, glibc */
  795. /*"CP54936", Windows */
  796. ),
  797. gb18030,
  798. { gb18030_mbtowc, NULL }, { gb18030_wctomb, NULL })
  799. DEFENCODING(( "ISO-2022-CN", /* IANA, RFC 1922 */
  800. "csISO2022CN",
  801. /*"ISO2022CN", JDK 1.1 */
  802. ),
  803. iso2022_cn,
  804. { iso2022_cn_mbtowc, NULL }, { iso2022_cn_wctomb, iso2022_cn_reset })
  805. DEFENCODING(( "ISO-2022-CN-EXT", /* IANA, RFC 1922 */
  806. ),
  807. iso2022_cn_ext,
  808. { iso2022_cn_ext_mbtowc, NULL }, { iso2022_cn_ext_wctomb, iso2022_cn_ext_reset })
  809. DEFENCODING(( "HZ", /* RFC 1843 */
  810. "HZ-GB-2312", /* IANA, RFC 1842 */
  811. ),
  812. hz,
  813. { hz_mbtowc, NULL }, { hz_wctomb, hz_reset })
  814. DEFENCODING(( "EUC-TW", /* glibc */
  815. "EUCTW", /* glibc, HP-UX, IRIX, OSF/1 */
  816. "csEUCTW",
  817. /*"EUC_TW", JDK 1.1 */
  818. /*"CP51950", Windows */
  819. ),
  820. euc_tw,
  821. { euc_tw_mbtowc, NULL }, { euc_tw_wctomb, NULL })
  822. #ifdef USE_AIX_ALIASES
  823. DEFALIAS( "IBM-EUCTW", /* AIX */
  824. euc_tw)
  825. #endif
  826. #ifdef USE_SOLARIS_ALIASES
  827. DEFALIAS( "CNS11643", /* Solaris */
  828. euc_tw)
  829. #endif
  830. DEFENCODING(( "BIG5", /* IANA, JDK 1.1 */
  831. "BIG-5", /* glibc */
  832. "BIG-FIVE", /* glibc */
  833. "BIGFIVE", /* glibc */
  834. "CN-BIG5", /* RFC 1922 */
  835. "csBig5", /* IANA */
  836. ),
  837. ces_big5,
  838. { ces_big5_mbtowc, NULL }, { ces_big5_wctomb, NULL })
  839. DEFENCODING(( "CP950", /* JDK 1.1 */
  840. ),
  841. cp950,
  842. { cp950_mbtowc, NULL }, { cp950_wctomb, NULL })
  843. DEFENCODING(( "BIG5-HKSCS:1999",
  844. ),
  845. big5hkscs1999,
  846. { big5hkscs1999_mbtowc, big5hkscs1999_flushwc }, { big5hkscs1999_wctomb, big5hkscs1999_reset })
  847. DEFENCODING(( "BIG5-HKSCS:2001",
  848. ),
  849. big5hkscs2001,
  850. { big5hkscs2001_mbtowc, big5hkscs2001_flushwc }, { big5hkscs2001_wctomb, big5hkscs2001_reset })
  851. DEFENCODING(( "BIG5-HKSCS", /* IANA */
  852. "BIG5HKSCS", /* glibc */
  853. "BIG5-HKSCS:2004",
  854. ),
  855. big5hkscs2004,
  856. { big5hkscs2004_mbtowc, big5hkscs2004_flushwc }, { big5hkscs2004_wctomb, big5hkscs2004_reset })
  857. DEFENCODING(( "EUC-KR", /* IANA, RFC 1557 */
  858. "EUCKR", /* glibc, HP-UX, IRIX, OSF/1 */
  859. "csEUCKR", /* IANA */
  860. /*"EUC_KR", JDK 1.1 */
  861. /*"CP51949", Windows */
  862. ),
  863. euc_kr,
  864. { euc_kr_mbtowc, NULL }, { euc_kr_wctomb, NULL })
  865. #ifdef USE_AIX_ALIASES
  866. DEFALIAS( "IBM-EUCKR", /* AIX */
  867. euc_kr)
  868. #endif
  869. #ifdef USE_OSF1_ALIASES
  870. DEFALIAS( "DECKOREAN", /* OSF/1 */
  871. euc_kr)
  872. #endif
  873. #ifdef USE_SOLARIS_ALIASES
  874. DEFALIAS( "5601", /* Solaris */
  875. euc_kr)
  876. #endif
  877. DEFENCODING(( "CP949", /* JDK 1.1 */
  878. "UHC", /* glibc */
  879. ),
  880. cp949,
  881. { cp949_mbtowc, NULL }, { cp949_wctomb, NULL })
  882. #ifdef USE_OSF1_ALIASES
  883. DEFALIAS( "KSC5601", /* OSF/1 */
  884. cp949)
  885. #endif
  886. DEFENCODING(( "JOHAB", /* glibc */
  887. "CP1361", /* glibc */
  888. ),
  889. johab,
  890. { johab_mbtowc, NULL }, { johab_wctomb, NULL })
  891. #ifdef USE_SOLARIS_ALIASES
  892. DEFALIAS( "KO_KR.JOHAP92", /* Solaris */
  893. johab)
  894. #endif
  895. DEFENCODING(( "ISO-2022-KR", /* IANA, RFC 1557 */
  896. "csISO2022KR", /* IANA */
  897. /*"ISO2022KR", JDK 1.1 */
  898. ),
  899. iso2022_kr,
  900. { iso2022_kr_mbtowc, NULL }, { iso2022_kr_wctomb, iso2022_kr_reset })
  901. #endif