Using Cabal to install terminfo-0.4.0.0 breaks GHC on Debian x86_64
austin at well-typed.com
Mon Apr 14 13:07:29 UTC 2014
Can I ask if you're installing packages into the global user database?
If so, that's definitely the way for this to happen - otherwise, Cabal
should never overwrite *anything* in the 'global' package directory
(in your case, under /usr/local/lib/ghc-7.8.2...) This is the only way
I can see this happening. In particular, installing 'terminfo' into my
local package database ('cabal install terminfo') works fine...
Carefully review your cabal configuration if you don't mind. You can
also always force the installation using '--user' when running cabal.
However, thank you very much for bringing this to my attention. What
you have discovered is a real brainfart I don't think we had
considered! The problem is that now that GHC is dynamically linked, we
*cannot* get away with lying about whether those packages are
installed - because they must install shared objects for GHC itself to
work. That means overwriting them by accident (because we don't think
they're installed) is a real possibility.
Relatedly, the NixOS Haskell users are suffering from the same problem
with 7.8.2 - http://lists.science.uu.nl/pipermail/nix-dev/2014-April/012992.html
- same problem, slightly different symptoms.
See https://ghc.haskell.org/trac/ghc/ticket/8919 for the ticket.
So this is definitely a real problem. I think scheduling the change
for 7.8.3 is correct.
My intuition tells me the fix might actually be quite simple - don't
lie about xhtml and terminfo being installed, and just be honest. Is
there any particular downside to doing this? I don't think so, *other*
than the fact it does mean terminfo has to come along when it's not
part of the Haskell Platform!
On Mon, Apr 14, 2014 at 7:08 AM, Ramin Honary <ramin.honary at gmail.com> wrote:
> I am using Debian, not Mac. It is possible the problem may be with the
> binary release for Debian x86_64, or it could just be my Cabal config file.
> When I install the binary distribution onto Debian, I simply run "make
> install" in the ghc-7.8.2 directory. I don't know how this install process
> the creates the GHC package registry, but after a fresh install, the output
> of the "ghc-pkg list" command shows that "terminfo-0.4.0.0" is NOT installed
> even though there the /usr/local/lib/ghc-7.8.2/terminfo-0.4.0.0 directory
> clearly exists and is populated with the correct library files. But since it
> is not registered Cabal tries to re-build it and overwrites the existing
> "terminfo-0.4.0.0" package.
> After a fresh install on Mac or Fedora, I wonder if "terminfo-0.4.0.0" shows
> up in the GHC package registry? It could be the package registry for the
> Debian binary distribution missed that detail.
> Glasgow-haskell-users mailing list
> Glasgow-haskell-users at haskell.org
Austin Seipp, Haskell Consultant
Well-Typed LLP, http://www.well-typed.com/
More information about the Glasgow-haskell-users