[Haskell-cafe] shakespeare >= 2.0.2 fails to install in OS X 10.6.8, Haskell-platform 2014.2.0.0; cabal-install 1.22.4.0

Mark Lentczner mark.lentczner at gmail.com
Fri Jun 19 14:35:54 UTC 2015


HP 2014.2.0.0 for Mac OS X is built with a bindist of GHC 7.8.3 that
*is* compiled
with support for 10.6.

To remove HP from a system, you can use the handy unisntall-hs command -
that does a better job than just poking around by hand.

There does appear to be a problem with Template Haskell, and loading some
packages that depend on yet other packages to be loaded... For some reason
dynamic loading in this case doesn't resolve. Fortunately there is a
workaround:

​When you see a message like:

Loading package parsec-3.1.5 ... <command line>: can't load .so/.DLL for:
/Library/Haskell/ghc-7.8.3-x86_64/lib/parsec-3.1.5/
libHSparsec-3.1.5-ghc7.8.3.dylib (dlopen(/Library/Haskell/ghc-
7.8.3-x86_64/lib/parsec-3.1.5/libHSparsec-3.1.5-ghc7.8.3.dylib, 9): *Library
not loaded: @rpath/libHStext-1.1.0.0-ghc7.**8.3.dylib*
  Referenced from: /Library/Haskell/ghc-7.8.3-x86_64/lib/parsec-3.1.5/
libHSparsec-3.1.5-ghc7.8.3.dylib
  Reason: image not found)


Look at the part in red. It indicates that *text *can't be loaded. You need
to add it's libdir to an export like so (you are adding the location of the
libHStext... file, which is always in a similarly named directory under
/Library/Haskell/ghc-7.8.3-x86_64/lib):

export DYLD_FALLBACK_LIBRARY_PATH=/Library/Haskell/ghc-
7.8.3-x86_64/lib/text-1.1.0.0:$DYLD_FALLBACK_LIBRARY_PATH


Rebuild, and you may see another to add, and you'll have to do this again.
To build shaekespeare-2.0.4.1 on a stock HP 2014.2.0.0 install, I needed to
add the following libs to that path primitive, hashable, mtl, and text.

I don't yet know if this is a bug in the way the HP libs were built, the
way GHC was built, or just a fundamental problem of GHC 7.8.3 (and later)
and OS X 10.6.

- Mark
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/haskell-cafe/attachments/20150619/9c29df8f/attachment.html>


More information about the Haskell-Cafe mailing list