Skip to content

emscripten ports ICU missing icudt #10129

@ldubost

Description

@ldubost

When compiling with USE_ICU, I'm getting the following error:

no symbols
no symbols
no symbols
no symbols
wasm-ld: error: /emsdk/.data/cache/wasm-obj/libicuuc.a(udata_a5e23168.cpp.o): undefined symbol: icudt62_dat
wasm-ld: error: /emsdk/.data/cache/wasm-obj/libicuuc.a(udata_a5e23168.cpp.o): undefined symbol: icudt62_dat
shared:ERROR: '/emsdk/upstream/bin/wasm-ld -o /tmp/emscripten_temp__hLcSu/x2t.wasm --allow-undefined --lto-O0 --no-check-features ./build/bin/linux_32/x2t.bc -L/emsdk/upstream/emscripten/system/local/lib ./build/lib/linux_32/libCryptoPPLib.a -L/emsdk/upstream/emscripten/system/lib ./build/lib/linux_32/libXlsFormatLib.a -L/emsdk/.data/cache/wasm-obj ./build/lib/linux_32/libkernel.so ./build/lib/linux_32/libgraphics.so ./build/lib/linux_32/libUnicodeConverter.so ./Common/3dParty/boost/boost_1_58_0/stage/lib/libboost_regex.a /emsdk/.data/cache/wasm-obj/libicuuc.a /emsdk/.data/cache/wasm-obj/libc-mt.a /emsdk/.data/cache/wasm-obj/libcompiler_rt.a /emsdk/.data/cache/wasm-obj/libc-wasm.a /emsdk/.data/cache/wasm-obj/libc++-mt-noexcept.a /emsdk/.data/cache/wasm-obj/libc++abi-mt-noexcept.a /emsdk/.data/cache/wasm-obj/libdlmalloc-mt.a /emsdk/.data/cache/wasm-obj/libpthread-mt.a /emsdk/.data/cache/wasm-obj/libc_rt_wasm.a --import-memory --import-table --shared-memory -mllvm -combiner-global-alias-analysis=false -mllvm -enable-emscripten-sjlj -mllvm -disable-lsr --strip-debug --export __wasm_call_ctors --export __data_end --export main --export malloc --export free --export setThrew --export __errno_location --export fflush --export emscripten_get_global_libc --export __pthread_tsd_run_dtors --export _register_pthread_ptr --export pthread_self --export __emscripten_pthread_data_constructor --export emscripten_futex_wake --export memalign --export usleep --export _ZSt18uncaught_exceptionv --export htonl --export htons --export ntohs --export realloc --export _get_tzname --export _get_daylight --export _get_timezone --export _get_environ --export emscripten_builtin_memalign --export emscripten_builtin_free -z stack-size=5242880 --initial-memory=149880832 --no-entry --max-memory=149880832 --global-base=1024' failed (1)

Here is the final build command:

gcc -Wl,--no-check-features -O0 -s USE_ICU=1 -s ERROR_ON_UNDEFINED_SYMBOLS=0 -s USE_PTHREADS=1 -s EXTRA_EXPORTED_RUNTIME_METHODS=["ccall"] -s EXPORT_ALL=1 -s ERROR_ON_UNDEFINED_SYMBOLS=0 -s TOTAL_MEMORY=149880832 -s WASM=1 ./build/bin/linux_32/x2t
.bc ./build/lib/linux_32/libCryptoPPLib.a ./build/lib/linux_32/libXlsFormatLib.a ./build/lib/linux_32/libkernel.so ./build/lib/linux_32/libgraphics.so ./build/lib/linux_32/libUnicodeConverter.so ./Common/3dParty/boost/boost_1_58_0/stage/lib/libboo
st_regex.a -lnodefs.js -o x2t.js

The build works when not using USE_ICU=1 but I'm then missing the icu methos:

warning: undefined symbol: ucnv_close_62
warning: undefined symbol: ucnv_fromUnicode_62
warning: undefined symbol: ucnv_getCCSID_62
warning: undefined symbol: ucnv_getMaxCharSize_62
warning: undefined symbol: ucnv_getMinCharSize_62
warning: undefined symbol: ucnv_getName_62
warning: undefined symbol: ucnv_openCCSID_62
warning: undefined symbol: ucnv_open_62
warning: undefined symbol: ucnv_toUnicode_62

which makes some part of the code fail while other parts are working.

It seems the libicudata is normally a separate library but it does not seem to be build in the ICU port.

If more info is needed I'm happy to provide it.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions