voikko / corevoikko

Libvoikko and essential linguistic resources
Other
89 stars 25 forks source link

Dictionary hdn gives runtime locale error #25

Closed snomos closed 8 years ago

snomos commented 8 years ago

To reproduce, install the attached zip file in the dictionary search path (rename .zip to .zhfst). Then do:

$ voikkospell -l
hdn-x-standard: Giellatekno/Divvun/UiT fst-based speller for Northern Haida
$ voikkospell -L
spell:hdn
$ echo nuvviDspeller | voikkospell -s -d hdn
terminate called after throwing an instance of 'std::runtime_error'
  what():  locale::facet::_S_create_c_locale name not valid
Abort trap: 6

The zhfst file itself is ok, at least as seen by hfst-ospell:

$ echo nuvviDspeller | hfst-ospell -S tools/spellcheckers/fstbased/desktop/hfst/hdn.zhfst 
"nuvviDspeller" is NOT in the lexicon:
Corrections for "nuvviDspeller":
Divvun speller for Northern Haida    1.000000
hdn version 0.1, 01.04.2016, rev131684    2.000000
Built using HFST 3.9.2, rev    3.000000

hdn.zip

snomos commented 8 years ago

Forget this error report. It turned out that libvoikko was compiled with a mixture of different compilers (GCC 5.1 & Clang) due to an old installation of GCC 5.1. After removing it, and recompiling hfst-ospell and then libvoikko with only clang, the error reported disappeared. Sorry for the noise.