Files
haskell.nix/docs/tutorials/pkg-map.md
T
Domen Kožar 2852a9521f Reorganize tutorials (#702)
* fix hackage and stackage to work

* user-guides -> tutorials

* Restructure tutorials

* getting-started: clarify on packages and components

* Update docs/tutorials/development.md

Co-authored-by: Rodney Lorrimar <dev@rodney.id.au>

* getting-started: bail out if cabal.project and stack.yaml are present

* hackage-stackage: delete duplicated content

Co-authored-by: Rodney Lorrimar <dev@rodney.id.au>
2020-06-19 13:37:02 +12:00

1.7 KiB

Mapping non-Haskell dependencies to Nixpkgs

Cabal files may contain dependencies to external non-Haskell dependencies via:

If there is a pkgs attribute in Nixpkgs that matches the name given in the Cabal file, then it will be added as a dependency (see the output of cabal-to-nix). Otherwise, there needs to be a mapping from Cabal file names (decided by the package author) to Nix package identifiers.

Nixpkgs overlay

The user may solve it by themself by overriding Nixpkgs and adding a package alias. For example:

nixpkgs.overlays = [
  (self: super: {
    icuuc = self.icu;
    icui18n = self.icu;
    icudata = self.icu;
  })
];

Mapping in Haskell.nix

Alternatively, if the name is commonly used, an alias can be added to the Haskell.nix sources, so that it's solved for all users.

!!! tip "Open a PR" Please go ahead and open a pull request to improve the package mappings.