Skip to content

Commit 4752ebf

Browse files
committed
Changes for building with Nix and GHC 7.8.4
1 parent d83d5a0 commit 4752ebf

File tree

3 files changed

+57
-3
lines changed

3 files changed

+57
-3
lines changed

default.nix

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
{ pkgs ? (import <nixpkgs> { config = {
2+
allowUnfree = true; # because we haven't set license params
3+
allowBroken = true;
4+
};})
5+
}:
6+
7+
let
8+
haskellPkgs = pkgs.haskell-ng.packages.ghc784;
9+
10+
inherit (pkgs) stdenv;
11+
inherit (pkgs.haskell-ng.lib) dontCheck dontHaddock;
12+
13+
callPackage = stdenv.lib.callPackageWith
14+
(pkgs // haskellPkgs // haskellDeps // gitlib);
15+
16+
gitlib = {
17+
gitlib = callPackage ./gitlib {};
18+
gitlib-cmdline = callPackage ./gitlib-cmdline {};
19+
gitlib-cross = callPackage ./gitlib-cross {};
20+
gitlib-github = callPackage ./gitlib-github {};
21+
gitlib-hit = callPackage ./gitlib-hit {};
22+
gitlib-lens = callPackage ./gitlib-lens {};
23+
hlibgit2 = callPackage ./hlibgit2 {};
24+
gitlib-libgit2 = callPackage ./gitlib-libgit2 {};
25+
gitlib-s3 = callPackage ./gitlib-s3 {};
26+
gitlib-sample = callPackage ./gitlib-sample {};
27+
gitlib-test = callPackage ./gitlib-test {};
28+
gitlib-utils = callPackage ./gitlib-utils {};
29+
git-gpush = callPackage ./git-gpush {};
30+
git-monitor = callPackage ./git-monitor {};
31+
};
32+
33+
haskellDeps = pkgs.recurseIntoAttrs {
34+
# #filepath = haskellPkgs.filepath_1_4_0_0;
35+
# filepath = callPackage ./nix/filepath.nix {};
36+
transformers =
37+
if pkgs.stdenv.lib.versionOlder haskellPkgs.ghc.version "7.7"
38+
then haskellPkgs.transformers_0_3_0_0
39+
else haskellPkgs.transformers;
40+
};
41+
42+
in {
43+
gitlib = gitlib;
44+
deps = haskellDeps;
45+
46+
gitlib-libgit2 = gitlib.gitlib-libgit2;
47+
48+
gitlibTestEnv = with haskellPkgs; with gitlib; pkgs.myEnvFun {
49+
name = "gitlibTest";
50+
buildInputs = [ gitlib-libgit2 gitlib-cmdline ] ++ [
51+
ghc cabal-install
52+
];
53+
};
54+
}

gitlib-libgit2/default.nix

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
, lifted-async, lifted-base, mmorph, monad-control, monad-logger
55
, monad-loops, mtl, resourcet, stdenv, stm, stm-conduit, tagged
66
, template-haskell, text, text-icu, time, transformers
7-
, transformers-base
7+
, transformers-base, missing-foreign
88
}:
99
mkDerivation {
1010
pname = "gitlib-libgit2";
@@ -15,7 +15,7 @@ mkDerivation {
1515
exceptions fast-logger filepath gitlib hlibgit2 lifted-async
1616
lifted-base mmorph monad-control monad-logger monad-loops mtl
1717
resourcet stm stm-conduit tagged template-haskell text text-icu
18-
time transformers transformers-base
18+
time transformers transformers-base missing-foreign
1919
];
2020
testDepends = [
2121
base exceptions gitlib gitlib-test hspec hspec-expectations HUnit

gitlib/gitlib.cabal

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ Library
4747
, containers >= 0.4.2.1
4848
, directory >= 1.1.0.2
4949
, exceptions >= 0.5
50-
, filepath >= 1.4
50+
, filepath >= 1.3
5151
, hashable >= 1.1.2.5
5252
, lifted-async >= 0.1.1
5353
, lifted-base >= 0.2

0 commit comments

Comments
 (0)