haskell / text-icu

This package provides the Haskell Data.Text.ICU library, for performing complex manipulation of Unicode text.
BSD 2-Clause "Simplified" License
47 stars 41 forks source link

Can't load updated libicu #33

Open ismailmustafa opened 7 years ago

ismailmustafa commented 7 years ago

Not sure if this is the right place for this but when attempting to build haskell-ide-engine which relies on text-icu as a dependency, it complains about the following:

Library not loaded: /usr/local/opt/icu4c/lib/libicuuc.58.dylib

However when running brew install icu4c, it installs the latest version which is 59.1. Does support for ICU 59.1 need to be added to text-icu or is this issue just unrelated?

More info regarding the error message can be found here https://github.com/haskell/haskell-ide-engine/issues/303.

raichoo commented 6 years ago

I'm having the same issue on FreeBSD.

raichoo commented 6 years ago

Looks like this was related to stack reusing already built packages. I've removed all snapshots in question and rebuilt the project, now it works.

brandon-leapyear commented 4 years ago

:sparkles: This is an old work account. Please reference @brandonchinn178 for all future communication :sparkles:


Note that this package does not interface well with Homebrew, because in my experience, Homebrew doesn't really support pinned versions, and this would happen every time Homebrew updates its version of ICU. This breaks text-icu because the package is not rebuilt and stays linked to an old version of ICU. Not sure what a better solution looks like

vshabanov commented 2 years ago

Hard to say what to do here. ICU is actively developed and often updated to a new major version (there is a new Unicode revision almost every year, and ICU adds its own features as well). It's not like OpenSSL, where the interface is almost doesn't change, and only new algorithms or bug fixes are added.

So precise versioning (libicu58, libicu59, ...) is necessary.

Adding a symlink from libicu58 to libicu59 won't work in general case, since the new Unicode character blocks could be added, and the same function would return different results for the same input (like block code changing from NoBlock in ICU 68 to CyproMinoan in ICU 70). Some other algorithms may change as well, so versions are really different and not backwards compatible.

Neither stack nor cabal is checking for updates of system-wide libraries. No go there.

Perhaps the only two options are manual recompilation or statically linking the ICU library.