[Nix-dev] ghc-pkg check | maintaining multiple versions of haskell package

Dmitry Malikov malikov.d.y at gmail.com
Sat Sep 8 23:22:59 CEST 2012


Trying to add cabal-dev to nixpkgs.
Stucked on that error.

$> nix-build -A haskellPackages.cabalDev
these derivations will be built:
  /nix/store/cfcxkh75a05amz59cz45p6pknahwrx2z-cabal-dev-0.9.1.drv
building path(s)
`/nix/store/viys82zlzi7swvs209zvxn5m8wfbjk8r-cabal-dev-0.9.1'
building /nix/store/viys82zlzi7swvs209zvxn5m8wfbjk8r-cabal-dev-0.9.1
unpacking sources
unpacking source archive
/nix/store/wdd30wya8nb3visiyn60k6kz1ny0y2ds-cabal-dev-0.9.1.tar.gz
source root is cabal-dev-0.9.1
patching sources
configuring
[1 of 1] Compiling Main             ( Setup.hs, Setup.o )
Linking Setup ...
Configuring cabal-dev-0.9.1...
Setup: At least the following dependencies are missing:
mtl >=1.1 && <2.1, tar ==0.3.*, transformers ==0.2.*
builder for
`/nix/store/cfcxkh75a05amz59cz45p6pknahwrx2z-cabal-dev-0.9.1.drv' failed
with exit code 1
error: build of
`/nix/store/cfcxkh75a05amz59cz45p6pknahwrx2z-cabal-dev-0.9.1.drv' failed

So, what version of transformers I actually have?

$> ghc-pkg list | ack transformers
WARNING: there are broken packages.  Run 'ghc-pkg check' for more details.
/home/dmalikov/.nix-profile/bin/../lib/ghc-pkgs/ghc-7.4.1/transformers-0.2.2.0.installedconf:
    transformers-0.2.2.0
/home/dmalikov/.nix-profile/bin/../lib/ghc-pkgs/ghc-7.4.1/transformers-0.2.2.0.installedconf:
    transformers-0.2.2.0
/home/dmalikov/.nix-profile/bin/../lib/ghc-pkgs/ghc-7.4.1/transformers-0.3.0.0.installedconf:
    transformers-0.3.0.0
/home/dmalikov/.nix-profile/bin/../lib/ghc-pkgs/ghc-7.4.1/transformers-0.3.0.0.installedconf:
    transformers-0.3.0.0
/nix/var/nix/profiles/default/bin/../lib/ghc-pkgs/ghc-7.4.1/transformers-0.3.0.0.installedconf:
    transformers-0.3.0.0

Seems like I have that transformers-0.2.* version, but its not current.
How can I switch to transformers-0.2.* version? Nix-env -i transformers-0.2
didn't change anything.

ps.
Also, ghc-pkg tells me, that there are some broken packages. One of them is
vector, so I tried to unregister it.

$> sudo ghc-pkg unregister vector-0.9.1
Password:
Writing new package config file... ghc-pkg:
/home/dmalikov/.nix-profile/bin/../lib/ghc-pkgs/ghc-7.4.1/vector-0.9.1.installedconf:
you don't have permission to modify this file

How can I fix haskell packages and make `ghc-pkg check` happy?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.science.uu.nl/pipermail/nix-dev/attachments/20120908/ccf3a0ba/attachment.html 


More information about the nix-dev mailing list