[libvoikko] Libreoffice Voikko+HFST standalone extension for Mac issue

Sjur Moshagen sjurnm at mac.com
Tue Sep 13 16:50:20 EEST 2011

Den 13. sep. 2011 kl. 11.32 skrev Sjur Moshagen:

> Den 12. sep. 2011 kl. 20.56 skrev Sjur Moshagen:
>>> This is an error and means ZHfstOspeller is not linked into libvoikko.a.
>>> Try rebuilding everything with --disable-shared --enable-static and see if
>>> that helps.
>> I did, and nothing has changed, I still get the same warning + errors as long as I am using the *.a file. If I instead reference the *.dylib file (as the rest of the libraries linked with the *.oxt library), the error disappears, but the resulting *.oxt is non-functional on other systems than my own:(
> It seems to be really hard to force a build to use static libraries. Some details can be found here:
> http://developer.apple.com/library/mac/#qa/qa1393/_index.html
> In essence, I have to explicitly reference each lib I want to link for each library I build during the build process.
> I'll try to do that, and see what happens.

A working solution was to move all static libs that should be linked into a separate dir, and link them from that location. This seems to work for building libhfstospell.a and libvoikko.a, but ooovoikko still fails with unrecognised symbols.

Using the following command I can see there are still 367 undefined symbols in libvoikko.a:

$ nm -a alibs/libvoikko.a | grep ' U ' | sort -u | wc -l     367

Examples of missing symbols are:

                 U __ZN7hfst_ol13ZHfstOspeller10read_zhfstERKSs
                 U __ZN7hfst_ol13ZHfstOspeller11read_legacyERKSs
                 U __ZN7hfst_ol13ZHfstOspeller5spellERKSs
                 U __ZN7hfst_ol13ZHfstOspeller7suggestERKSs
                 U __ZN7hfst_ol13ZHfstOspellerC1Ev
                 U __ZN7hfst_ol13ZHfstOspellerD1Ev
                 U __ZN9libvoikko10hyphenator10HyphenatorD2Ev
                 U __ZN9libvoikko10hyphenator14HfstHyphenatorC1ERKSs

(U means Undefined)

Any help as to how to get the static build to work is really appreciated.


More information about the Libvoikko mailing list