[sword-devel] ICU transliteration resources
ransom1982 at gmail.com
Thu Feb 19 13:24:17 MST 2009
On Thu, Feb 19, 2009 at 3:13 PM, Chris Little <chrislit at crosswire.org> wrote:
> Matthew Talbert wrote:
>> I have successfully compiled ICU with mingw on Windows and I'm trying
>> to get the transliteration filters working. These now work in Xiphos
>> in linux. However, the location of the filters appears hard-coded in
>> utf8transliterator.cpp. Is there an interface to allow passing the
>> location at runtime? This is necessary for Windows where the location
>> is not known at compile time.
> None of the hard-coded paths are used in BibleCS. BibleCS finds its
> resources in the current directory (or using PATH if that fails) in the
> standard way that one locates DLLs. For details about why those hardcoded
> paths are in there, I believe you would have to ask Daniel Glassey.
> I believe there is also a way to pass locations of resource bundles at
> runtime, but I'm not sure what it is.
>> Additionally, I hardcoded the location into utf8transliterator.cpp,
>> and it apparently loaded the filters, but transliteration still wasn't
>> working in Xiphos. Is there some way to test that the resource files
>> are actually correct?
> If you build ICU from source, it should result in a program called uconv. If
> you run "uconv -L", it will list all of the transliterator resources
> available in whichever resource bundle(s) it is finding.
>> I do not understand how BibleCS is managing this, as I was unable to
>> even locate the resources in the installation.
> ICU resources are located in the file icudt40.dll ("40" being for version
> 4.0 and being adjusted accordingly for other releases of ICU). It's located
> in the program's directory, which is the same way Adobe Acrobat, Logos, etc.
> package their ICU DLL.
> Building & linking the ICU DLL is a bit complicated. Visual Studio is one of
> ICU's reference platforms, but Borland C++ Builder isn't even a supported
> platform. So we build the resource bundle lib & dll in VS, convert the lib
> from VS to Borland format, link against the converted lib, and ship the VS
> dll. So if it's possible to use/convert the VS lib and use the same dll as
> BibleCS, that might be the best solution for you. (I can send the lib file
> if you'd like to try.)
Thanks for the reply. It is much as I suspicioned. I do have Visual
Studio, and I was able to easily compile ICU with that, however it did
not give me an icudt that I could see. Perhaps I'd better look again.
Of considerable concern to me is whether I will be able to link
against that with gcc/g++ so I would rather use what I have currently.
I will try uconv and see what I get there.
More information about the sword-devel