summaryrefslogtreecommitdiff
path: root/gf.nix
diff options
context:
space:
mode:
authorInari Listenmaa <inari.listenmaa@gmail.com>2018-05-04 17:23:53 +0200
committerGitHub <noreply@github.com>2018-05-04 17:23:53 +0200
commit1c7e99cdca020ccb1e55b067961813a7752eba3b (patch)
tree397619af806b1a0937e8f731aa5187f258d48066 /gf.nix
parentbb5b21b925c898bd1962ec7563e2d8913a2c73a7 (diff)
parent42bcb5015467a359ae5f1acd180d2cab244d63a3 (diff)
Merge pull request #37 from mbrock/master
Fix the Nix build
Diffstat (limited to 'gf.nix')
-rw-r--r--gf.nix20
1 files changed, 18 insertions, 2 deletions
diff --git a/gf.nix b/gf.nix
index 4b7ed2092..2926651f3 100644
--- a/gf.nix
+++ b/gf.nix
@@ -1,3 +1,19 @@
-let pkgs = import <nixpkgs> {}; in rec {
- gf = pkgs.haskellPackages.callPackage ./default.nix {};
+let
+ # We import the package hierarchy from the NIX_PATH.
+ pkgs = import <nixpkgs> {};
+
+ #
+ # The `cgi` package has some out-of-date upper bounds.
+ # Instead of fixing that upstream, we can use the "jailbreak"
+ # function in Nix, which patches away the upper bounds.
+ #
+ # This isn't ideal, but it lets us build the dependency.
+ #
+ jailbreak = pkgs.haskell.lib.doJailbreak;
+ haskellPackages = pkgs.haskellPackages.extend (self: super: {
+ cgi = jailbreak super.cgi;
+ });
+
+in {
+ gf = haskellPackages.callPackage (import ./default.nix) {};
}