[Nix-dev] ghc --enable-multi-instance, the end of cabal hell ?
Miguel Negrão
miguel.negrao-lists at friendlyvirus.org
Mon Sep 21 11:23:22 CEST 2015
Hi Peter
> > Could the infrastructure used for this in ghc help in nixos?
>
> my understanding is that these patches solve a problem that we don't have in
> Nix. We can build any number of variants of the same library and install
all of
> them next to each other just fine. The --enable-multi-instance feature is
> important mostly for people who want to manage one big (system-wide) registry
> of known packages, but we don't do that in Nix.
Rereading the original link I realize that I misunderstood what they were
proposing, indeed it does not fix the type of issues I'm mentioning. I think
the issue I was thinking of is the "diamond problem" [1]:
package A
/ \
package C Package D
| |
package Ev1 PackageEv2
which can cause errors such as:
Couldn't match expected type `bytestring-0.9.0.4:Data.ByteString.ByteString'
against inferred type `bytestring-0.9.0.1:Data.ByteString.ByteString'
Actually, like it is mentioned in the post, this is solved in nix, because
you can install another version of D which uses Ev1 instead of Ev2.
best,
Miguel
[1]http://www.well-typed.com/blog/2008/04/the-dreaded-diamond-dependency-problem/
More information about the nix-dev
mailing list