diff options
author | Alexander Barkov <bar@mysql.com> | 2010-02-24 13:15:34 +0400 |
---|---|---|
committer | Alexander Barkov <bar@mysql.com> | 2010-02-24 13:15:34 +0400 |
commit | 8994fad85db18b4ab31fc67e2f8e15f1203d0b1a (patch) | |
tree | 469ee723904a6610a4436b55056ed5e2c19d9972 /config | |
parent | d2af6c43c0f7b62a6051d0c5f74c66f98dbefe7a (diff) | |
download | mariadb-git-8994fad85db18b4ab31fc67e2f8e15f1203d0b1a.tar.gz |
Backporting WL#1213
config/ac-macros/character_sets.m4:
- Adding configure definitions for utf8mb4, utf16, utf32
include/config-win.h:
- Enabling utf8mb4, utf16, utf32 in Windows build
include/m_ctype.h:
- Adding new flags
- Adding new shared functions prototypes
mysql-test/include/ctype_datetime.inc:
- Adding test to check that datetime functions
work with "real" multibyte character sets.
mysql-test/include/ctype_like.inc:
- Adding LIKE tests
mysql-test/include/have_utf16.inc:
New file
mysql-test/include/have_utf32.inc:
New file
mysql-test/include/have_utf8mb4.inc:
New file
mysql-test/r/ctype_ldml.result:
- Adding tests for utf8mb4, utf16, utf32
mysql-test/r/ctype_many.result:
- Adding tests to check superset/subset relations
between all Unicode character sets.
mysql-test/r/ctype_utf16.result:
New file
mysql-test/r/ctype_utf16_uca.result:
New file
mysql-test/r/ctype_utf32.result:
New file
mysql-test/r/ctype_utf32_uca.result:
New file
mysql-test/r/ctype_utf8.result:
- Adding tests for utf8mn3 alias
mysql-test/r/ctype_utf8mb4.result:
- Adding tests for utf8mb4
mysql-test/r/have_utf16.require:
New file
mysql-test/r/have_utf32.require:
New file
mysql-test/r/have_utf8mb4.require:
New file
mysql-test/std_data/Index.xml:
- Adding tests for loadable utf8m4, utf16, utf32 collations
mysql-test/suite/sys_vars/r/character_set_client_basic.result:
- Adding tests for utf16, utf32.
- Fixing new number of character sets
mysql-test/suite/sys_vars/r/character_set_connection_basic.result:
- Fixing new number of character sets
mysql-test/suite/sys_vars/r/character_set_database_basic.result:
- Fixing new number of character sets
mysql-test/suite/sys_vars/r/character_set_filesystem_basic.result:
- Fixing new number of character sets
mysql-test/suite/sys_vars/r/character_set_results_basic.result:
- Fixing new number of character sets
mysql-test/suite/sys_vars/t/character_set_client_basic.test:
- Adding tests for new character sets
mysql-test/suite/sys_vars/t/character_set_connection_basic.test:
- Adding dependency on utf8mb4, utf16, utf32
mysql-test/suite/sys_vars/t/character_set_database_basic.test:
- Adding dependency on utf8mb4, utf16, utf32
mysql-test/suite/sys_vars/t/character_set_filesystem_basic.test:
- Adding dependency on utf8mb4, utf16, utf32
mysql-test/suite/sys_vars/t/character_set_results_basic.test:
- Adding dependency on utf8mb4, utf16, utf32
mysql-test/t/ctype_ldml.test:
- Adding tests for dynamic utf8mb4, utf16, utf32 collations
mysql-test/t/ctype_many.test:
- Adding tests to check superset/subset relations
between all Unicode character sets
mysql-test/t/ctype_utf16.test:
New file
mysql-test/t/ctype_utf16_uca.test:
New file
mysql-test/t/ctype_utf32.test:
New file
mysql-test/t/ctype_utf32_uca.test:
New file
mysql-test/t/ctype_utf8.test:
- Adding tests for utf8mb4 alias
mysql-test/t/ctype_utf8mb4.test:
New file
mysys/charset-def.c:
- Adding initialization of utf8mb4, utf16, utf32 built-int collations
mysys/charset.c:
- Adding initialization of utf8mb4, utf16, utf32 dynamic collations
sql/field.cc:
- Fixing "truncated" error with datetime functions:
Force conversion in case of non-ascii character sets.
sql/item.cc:
- Adding superset/subset relation check for utf8mb4/utf8
sql/item_strfunc.cc:
- Fixing a problem with CHAR(x USING utf32)
sql/sql_string.cc:
- Fixing problems with zero padding for UTF32
sql/sql_table.cc:
- Fixing buffer size, to make utf32 comma fit.
strings/ctype-mb.c:
- Making handlers for multi-byte binary collations public
strings/ctype-uca.c:
- Adding definitions for utf8mb4, utf16, utf32 UCA collations
strings/ctype-ucs2.c:
- Adding functions which are shared between ucs2, utf16, utf32
- Ading utf16 implementation
- Adding utf32 implementation
strings/ctype-utf8.c:
- Adding functions shared between utf8 and utf8mb4
- Adding implementation of utf8mb4
Diffstat (limited to 'config')
-rw-r--r-- | config/ac-macros/character_sets.m4 | 65 |
1 files changed, 61 insertions, 4 deletions
diff --git a/config/ac-macros/character_sets.m4 b/config/ac-macros/character_sets.m4 index 24bdd92b083..81967d383ec 100644 --- a/config/ac-macros/character_sets.m4 +++ b/config/ac-macros/character_sets.m4 @@ -13,11 +13,11 @@ define(CHARSETS_AVAILABLE1,armscii8 ascii big5 cp1250 cp1251 cp1256 cp1257) define(CHARSETS_AVAILABLE2,cp850 cp852 cp866 cp932 dec8 eucjpms euckr gb2312 gbk geostd8) define(CHARSETS_AVAILABLE3,greek hebrew hp8 keybcs2 koi8r koi8u) define(CHARSETS_AVAILABLE4,latin1 latin2 latin5 latin7 macce macroman) -define(CHARSETS_AVAILABLE5,sjis swe7 tis620 ucs2 ujis utf8) +define(CHARSETS_AVAILABLE5,sjis swe7 tis620 ucs2 ujis utf8mb4 utf8 utf16 utf32) DEFAULT_CHARSET=latin1 CHARSETS_AVAILABLE="CHARSETS_AVAILABLE0 CHARSETS_AVAILABLE1 CHARSETS_AVAILABLE2 CHARSETS_AVAILABLE3 CHARSETS_AVAILABLE4 CHARSETS_AVAILABLE5" -CHARSETS_COMPLEX="big5 cp1250 cp932 eucjpms euckr gb2312 gbk latin1 latin2 sjis tis620 ucs2 ujis utf8" +CHARSETS_COMPLEX="big5 cp1250 cp932 eucjpms euckr gb2312 gbk latin1 latin2 sjis tis620 ucs2 ujis utf8mb4 utf8 utf16 utf32" AC_DIVERT_POP @@ -50,7 +50,7 @@ AC_ARG_WITH(extra-charsets, AC_MSG_CHECKING("character sets") -CHARSETS="$default_charset latin1 utf8" +CHARSETS="$default_charset latin1 utf8mb4 utf8" if test "$extra_charsets" = no; then CHARSETS="$CHARSETS" @@ -195,8 +195,23 @@ do AC_DEFINE([USE_MB], [1], [Use multi-byte character routines]) AC_DEFINE(USE_MB_IDENT, 1) ;; + utf8mb4) + AC_DEFINE(HAVE_CHARSET_utf8mb4, 1, [Define to enable utf8mb4]) + AC_DEFINE([USE_MB], 1, [Use multi-byte character routines]) + AC_DEFINE(USE_MB_IDENT, 1) + ;; utf8) - AC_DEFINE(HAVE_CHARSET_utf8, 1, [Define to enable ut8]) + AC_DEFINE(HAVE_CHARSET_utf8, 1, [Define to enable utf8]) + AC_DEFINE([USE_MB], 1, [Use multi-byte character routines]) + AC_DEFINE(USE_MB_IDENT, 1) + ;; + utf16) + AC_DEFINE(HAVE_CHARSET_utf16, 1, [Define to enable utf16]) + AC_DEFINE([USE_MB], 1, [Use multi-byte character routines]) + AC_DEFINE(USE_MB_IDENT, 1) + ;; + utf32) + AC_DEFINE(HAVE_CHARSET_utf32, 1, [Define to enable utf32]) AC_DEFINE([USE_MB], 1, [Use multi-byte character routines]) AC_DEFINE(USE_MB_IDENT, 1) ;; @@ -381,6 +396,48 @@ case $default_charset in fi default_charset_collations="$UTFC" ;; + utf8mb4) + default_charset_default_collation="utf8mb4_general_ci" + define(UTFC1, utf8mb4_general_ci utf8mb4_bin) + define(UTFC2, utf8mb4_czech_ci utf8mb4_danish_ci) + define(UTFC3, utf8mb4_esperanto_ci utf8mb4_estonian_ci utf8mb4_hungarian_ci) + define(UTFC4, utf8mb4_icelandic_ci utf8mb4_latvian_ci utf8mb4_lithuanian_ci) + define(UTFC5, utf8mb4_persian_ci utf8mb4_polish_ci utf8mb4_romanian_ci) + define(UTFC6, utf8mb4_sinhala_ci utf8mb4_slovak_ci utf8mb4_slovenian_ci) + define(UTFC7, utf8mb4_spanish2_ci utf8mb4_spanish_ci) + define(UTFC8, utf8mb4_swedish_ci utf8mb4_turkish_ci) + define(UTFC9, utf8mb4_unicode_ci) + UTFC="UTFC1 UTFC2 UTFC3 UTFC4 UTFC5 UTFC6 UTFC7 UTFC8 UTFC9" + default_charset_collations="$UTFC" + ;; + utf16) + default_charset_default_collation="utf16_general_ci" + define(UTFC1, utf16_general_ci utf16_bin) + define(UTFC2, utf16_czech_ci utf16_danish_ci) + define(UTFC3, utf16_esperanto_ci utf16_estonian_ci utf16_hungarian_ci) + define(UTFC4, utf16_icelandic_ci utf16_latvian_ci utf16_lithuanian_ci) + define(UTFC5, utf16_persian_ci utf16_polish_ci utf16_romanian_ci) + define(UTFC6, utf16_sinhala_ci utf16_slovak_ci utf16_slovenian_ci) + define(UTFC7, utf16_spanish2_ci utf16_spanish_ci) + define(UTFC8, utf16_swedish_ci utf16_turkish_ci) + define(UTFC9, utf16_unicode_ci) + UTFC="UTFC1 UTFC2 UTFC3 UTFC4 UTFC5 UTFC6 UTFC7 UTFC8 UTFC9" + default_charset_collations="$UTFC" + ;; + utf32) + default_charset_default_collation="utf32_general_ci" + define(UTFC1, utf32_general_ci utf32_bin) + define(UTFC2, utf32_czech_ci utf32_danish_ci) + define(UTFC3, utf32_esperanto_ci utf32_estonian_ci utf32_hungarian_ci) + define(UTFC4, utf32_icelandic_ci utf32_latvian_ci utf32_lithuanian_ci) + define(UTFC5, utf32_persian_ci utf32_polish_ci utf32_romanian_ci) + define(UTFC6, utf32_sinhala_ci utf32_slovak_ci utf32_slovenian_ci) + define(UTFC7, utf32_spanish2_ci utf32_spanish_ci) + define(UTFC8, utf32_swedish_ci utf32_turkish_ci) + define(UTFC9, utf32_unicode_ci) + UTFC="UTFC1 UTFC2 UTFC3 UTFC4 UTFC5 UTFC6 UTFC7 UTFC8 UTFC9" + default_charset_collations="$UTFC" + ;; *) AC_MSG_ERROR([Charset $cs not available. (Available are: $CHARSETS_AVAILABLE). See the Installation chapter in the Reference Manual.]) |