/
default.nix
52 lines (48 loc) · 2.12 KB
/
default.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
{ compiler ? "ghc8107"
, system ? builtins.currentSystem
, haskellNix ? import
(builtins.fetchTarball
"https://github.com/input-output-hk/haskell.nix/archive/28dbf2f4bd32a4fbd1a2e9de45d02ad977b062d9.tar.gz")
{ }
, iohkNix ? import
(builtins.fetchTarball
"https://github.com/input-output-hk/iohk-nix/archive/62d853d3216083ecadc8e7f192498bebad4eee76.tar.gz")
{ }
# nixpkgs-unstable as also used by cardano-node, cardano-ledger et al
, nixpkgsSrc ? builtins.fetchTarball "https://github.com/NixOS/nixpkgs/archive/1882c6b7368fd284ad01b0a5b5601ef136321292.tar.gz"
, nixpkgsArgs ? haskellNix.nixpkgsArgs
}:
let
pkgs = import nixpkgsSrc (nixpkgsArgs // {
overlays =
# Haskell.nix (https://github.com/input-output-hk/haskell.nix)
haskellNix.overlays
# needed for cardano-crypto-class which uses a patched libsodium
++ iohkNix.overlays.crypto;
});
in
pkgs.haskell-nix.project {
src = pkgs.haskell-nix.haskellLib.cleanGit {
name = "hydra-poc";
src = ./.;
};
projectFileName = "cabal.project";
compiler-nix-name = compiler;
modules = [{
packages = {
eventful-sql-common = {
# This is needed so evenful-sql-common will build with a newer version of persistent.
ghcOptions = [ "-XDerivingStrategies -XStandaloneDeriving -XUndecidableInstances -XDataKinds -XFlexibleInstances -XMultiParamTypeClasses" ];
doHaddock = false;
};
# Broken due to haddock errors. Refer to https://github.com/input-output-hk/plutus/blob/master/nix/pkgs/haskell/haskell.nix
plutus-ledger.doHaddock = false;
plutus-use-cases.doHaddock = false;
};
# https://github.com/input-output-hk/cardano-wallet/commit/ced95e1b84ce8d9faa53268be45e96701ccc16e9
packages.cardano-config.components.library.build-tools = [ pkgs.buildPackages.buildPackages.gitMinimal ];
# https://github.com/input-output-hk/iohk-nix/pull/488
packages.cardano-crypto-class.components.library.pkgconfig = pkgs.lib.mkForce [ [ pkgs.libsodium-vrf pkgs.secp256k1 ] ];
packages.cardano-crypto-praos.components.library.pkgconfig = pkgs.lib.mkForce [ [ pkgs.libsodium-vrf ] ];
}];
}