[Nix-dev] overview about hack-nix and how it works
Marc Weber
marco-oweber at gmx.de
Wed Aug 10 16:53:26 CEST 2011
Excerpts from Juan Daugherty's message of Mon Aug 08 18:44:56 +0200 2011:
> Now loading metadata ...
> packageInfo not found for file-embed-0.0.4.1
> packageInfo not found for hjsmin-0.0.14
> packageInfo not found for entropy-0.1
> [.. snip]
Pasting a couple of failures should be enough.
LEKSAH ISSUE 1)
It's a well known issue nobody cared enough to fix yet. Try this:
nix-build -iA haskellPackages.ghc.ghc -f /etc/nixos/nixpkgs/default.nix # unwrapped ghc
result/bin/ghc-pkg list
nix-build -iA haskellPackages.ghc -f /etc/nixos/nixpkgs/default.nix # wrapped ghc
result/bin/ghc-pkg list
The first one will show core packages. The last one will show additional
(no core) packages only.
Try putting the .ghc.ghc version of ghc in PATH, rm -fr ~/.leksah-0.10/
and suddenly the core packages will appear (they did here).
That's no fix. Its only a hint what might be wrong
LEKSAH ISSUE 2)
leksah depends on cabal to build packages and looks in
/nix/store/*leksah*/bin/ which of course does not contain cabal. It does
on most other systems. The fix is trivial: Patch and make leksah use
findExecutable instead.
Probably this issue does not exist if you install everything into
~/.nix-profile ? I haven't tried.
In the past I mantained a ghc-pkg patch which was able to merge many
package databases (or write one based on GHC_PACKAGE_PATH which is not
used very often - so most tools including leksah and cabal library
ignore it :-( ). I got tired of keeping the cabal patch up to date
also because merging using darcs was no fun.
However it was a lot of work and broke several times and Andres Loeh ghc
wrapper which traverses PATH worked good enough. I'd call it a hack
because of ISSUE 1).
Do you care enough about this all to help working on a solution?
Marc Weber
More information about the nix-dev
mailing list