FS#56362 - Haskell Cabal broken

Attached to Project: Arch Linux
Opened by Nicola Squartini (tensor5) - Friday, 17 November 2017, 20:35 GMT
Last edited by Doug Newgard (Scimmia) - Saturday, 18 November 2017, 19:17 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To No-one
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

When trying to install a Haskell package with cabal install, or buid with cabal build, I end up with a bunch of messages of missing packages:

src/Control/Monad/Base.hs:17:8: error:
Could not find module ‘Prelude’
There are files missing in the ‘base-4.10.0.0’ package,
try running 'ghc-pkg check'.
Use -v to see a list of the files searched for.
|
17 | module Control.Monad.Base
| ^^^^^^^^^^^^^^^^^^

src/Control/Monad/Base.hs:22:1: error:
Could not find module ‘Data.Monoid’
There are files missing in the ‘base-4.10.0.0’ package,
try running 'ghc-pkg check'.
Use -v to see a list of the files searched for.
|
22 | import Data.Monoid
| ^^^^^^^^^^^^^^^^^^

src/Control/Monad/Base.hs:23:1: error:
Could not find module ‘Data.Functor.Identity’
There are files missing in the ‘base-4.10.0.0’ package,
try running 'ghc-pkg check'.
Use -v to see a list of the files searched for.
|
23 | import Data.Functor.Identity
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

[...]


Moreover if I run ghc-pkg check I get things like:

Warning: haddock-interfaces: /usr/share/doc/haskell-zlib/html/zlib.haddock doesn't exist or isn't a file
Warning: haddock-html: /usr/share/doc/haskell-zlib/html doesn't exist or isn't a directory
Warning: haddock-interfaces: /usr/share/doc/haskell-transformers-compat/html/transformers-compat.haddock doesn't exist or isn't a file
Warning: haddock-html: /usr/share/doc/haskell-transformers-compat/html doesn't exist or isn't a directory
Warning: haddock-interfaces: /usr/share/doc/haskell-text/html/text.haddock doesn't exist or isn't a file
Warning: haddock-html: /usr/share/doc/haskell-text/html doesn't exist or isn't a directory
[...]


Additional info:
* package version(s)

ghc 8.2.1
cabal 2.0.0.0


Steps to reproduce:

cabal install rocksdb-haskell
This task depends upon

Closed by  Doug Newgard (Scimmia)
Saturday, 18 November 2017, 19:17 GMT
Reason for closing:  Not a bug
Comment by Levente Polyak (anthraxx) - Friday, 17 November 2017, 21:14 GMT
we use dynamically linked libraries, you should try something like
cabal install rocksdb-haskell --enable-shared --enable-executable-dynamic --disable-library-vanilla --dynlibdir=/usr/lib --libsubdir=\$compiler/site-local/\$pkgid

PS: if you side-load stuff as root into the system you will end up with same possible collision/problems as with pip or gems
Comment by Nicola Squartini (tensor5) - Saturday, 18 November 2017, 19:12 GMT
Thanks, it works with --enable-shared --enable-executable-dynamic --disable-library-vanilla.

Loading...