Fix support data loading with system ICU
This commit is contained in:
committed by
Travis Wrightsman
parent
71a9948157
commit
ed0efc4791
@ -25,6 +25,9 @@ if "svg" in env.module_list:
|
|||||||
# Enable ThorVG static object linking.
|
# Enable ThorVG static object linking.
|
||||||
env_text_server_adv.Append(CPPDEFINES=["TVG_STATIC"])
|
env_text_server_adv.Append(CPPDEFINES=["TVG_STATIC"])
|
||||||
|
|
||||||
|
if env["builtin_icu4c"]:
|
||||||
|
env_text_server_adv.Append(CPPDEFINES=["HAVE_ICU_BUILTIN"])
|
||||||
|
|
||||||
if env["builtin_harfbuzz"]:
|
if env["builtin_harfbuzz"]:
|
||||||
env_harfbuzz = env_modules.Clone()
|
env_harfbuzz = env_modules.Clone()
|
||||||
env_harfbuzz.disable_warnings()
|
env_harfbuzz.disable_warnings()
|
||||||
|
|||||||
@ -434,7 +434,7 @@ bool TextServerAdvanced::_has(const RID &p_rid) {
|
|||||||
bool TextServerAdvanced::_load_support_data(const String &p_filename) {
|
bool TextServerAdvanced::_load_support_data(const String &p_filename) {
|
||||||
_THREAD_SAFE_METHOD_
|
_THREAD_SAFE_METHOD_
|
||||||
|
|
||||||
#ifdef ICU_STATIC_DATA
|
#if defined(ICU_STATIC_DATA) || !defined(HAVE_ICU_BUILTIN)
|
||||||
if (!icu_data_loaded) {
|
if (!icu_data_loaded) {
|
||||||
UErrorCode err = U_ZERO_ERROR;
|
UErrorCode err = U_ZERO_ERROR;
|
||||||
u_init(&err); // Do not check for errors, since we only load part of the data.
|
u_init(&err); // Do not check for errors, since we only load part of the data.
|
||||||
|
|||||||
Reference in New Issue
Block a user