+ Add ACCEPT_646 for systems that return '646' for nl_langinfo(CODESET) call

git-svn-id: trunk@20905 -
This commit is contained in:
pierre 2012-04-17 15:28:28 +00:00
parent 8750b10113
commit 7d82ed4459
2 changed files with 8 additions and 1 deletions

View File

@ -99,6 +99,7 @@ const
_NL_CTYPE_CODESET_NAME = (_NL_CTYPE_CLASS)+14;
CODESET = 0; // _NL_CTYPE_CODESET_NAME;
{$elseif defined(solaris)}
{$define ACCEPT_646}
CODESET=49;
LC_ALL = 6;
{$elseif defined(beos)}
@ -111,9 +112,11 @@ const
{$endif}
ESysEILSEQ = EILSEQ;
{$elseif defined(OpenBSD)}
{$define ACCEPT_646}
CODESET = 51;
LC_ALL = 0;
{$elseif defined(NetBSD)}
{$define ACCEPT_646}
CODESET = 51;
LC_ALL = 0;
{$elseif defined(aix)}

View File

@ -12,7 +12,8 @@ end;
* http://msdn2.microsoft.com/en-us/library/ms776446.aspx
*)
const
win2iconv_arr: array[-1..406{$ifndef aix}-83{$endif}] of twin2iconv =
win2iconv_array_limit = 406{$ifndef aix}-83{$endif}{$ifdef ACCEPT_646}+1{$endif};
win2iconv_arr: array[-1..win2iconv_array_limit] of twin2iconv =
((cp:0; name: 'UTF-8'), { invalid/unknown -> utf-8 }
(cp:37; name:'IBM037'), (* IBM EBCDIC US-Canada *)
(cp:37; name:'IBM-037'), (* IBM EBCDIC US-Canada, AIX *)
@ -342,6 +343,9 @@ win2iconv_arr: array[-1..406{$ifndef aix}-83{$endif}] of twin2iconv =
{$endif}
(cp:20127; name:'IBM367'),
(cp:20127; name:'ISO-IR-6'),
{$ifdef ACCEPT_646}
(cp:20127; name:'646'),
{$endif ACCEPT_646}
(cp:20127; name:'ISO646-US'),
(cp:20127; name:'ISO_646.IRV:1991'),
(cp:20127; name:'US'),