[Haskell-cafe] Problem building with Cabal + TH + Library with FFI to C++ via C Wrapper
Ozgun Ataman
ozataman at gmail.com
Tue Jun 28 21:19:40 CEST 2011
Dear Cafe,
I have recently run into a very annoying issue that I was not able to get
around. I have a local package that makes use of the snappy compression
library, which boasts bindings to C++ through a C wrapper.
Everything compiles fine with ghc --make, but cabal install hits a wall when
TemplateHaskell kicks in and decides to load the entire dependency chain.
Here is the important bit of the error message I get after running "cabal
install"
Loading package snappy-0.2.0.0 ... linking ... ghc:
/home/ubuntu/.cabal/lib/snappy-0.2.0.0/ghc-7.0.3/HSsnappy-0.2.0.0.o: unknown
symbol `_ZTV8BSSource'
ghc: unable to load package `snappy-0.2.0.0'
I'm quite certain all the libs are in PATH. "cabal install snappy" installs
fine when typed separately by itself and everything works fine (the program
works, including compression via snappy) when I compile my local package
with ghc --make.
The problem only occurs on a Ubuntu 64-bit server, and I wasn't able to
replicate the issue on my local OS X box. On my local, cabal install works
just fine.
I did find a previous note on Cafe with the exact same problem, but no
solution was posted at the time:
http://www.haskell.org/pipermail/haskell-cafe/2010-December/087748.html
Any help is much appreciated.
Cheers,
Ozgun
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20110628/e33fec46/attachment.htm>
More information about the Haskell-Cafe
mailing list