forked from johanatan/quickstrom
-
Notifications
You must be signed in to change notification settings - Fork 0
/
default.nix
51 lines (45 loc) · 1.84 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
{ pkgs ? import ./nixpkgs.nix { config = { allowBroken = true; }; }
, git-rev ? null, compiler ? "ghc865" }:
let
inherit (pkgs.lib.systems.elaborate { system = builtins.currentSystem; })
isLinux;
dsl = import ./dsl { inherit pkgs; };
client-side = import ./client-side { inherit pkgs; };
html-report = import ./html-report { inherit pkgs; };
haskellPackages = pkgs.haskell.packages.${compiler}.override {
overrides = self: super: {
base64 = pkgs.haskell.lib.dontCheck (super.base64);
tasty-quickcheck-laws =
pkgs.haskell.lib.dontCheck (super.tasty-quickcheck-laws);
webdriver-w3c = pkgs.haskell.lib.dontCheck (super.webdriver-w3c);
script-monad = pkgs.haskell.lib.dontCheck (super.script-monad);
protolude =
pkgs.haskell.lib.doJailbreak (self.callHackage "protolude" "0.2.3" { });
# haskell-src = self.callHackage "haskell-src" "1.0.3.0" { };
# HTF = pkgs.haskell.lib.dontCheck (self.callHackage "HTF" "0.13.2.5" { });
quickstrom-runner = pkgs.haskell.lib.disableLibraryProfiling
(import ./runner {
inherit pkgs;
haskellPackages = self;
});
quickstrom-cli = pkgs.haskell.lib.justStaticExecutables (import ./cli {
inherit pkgs git-rev;
haskellPackages = self;
});
};
};
quickstrom = pkgs.stdenv.mkDerivation {
name = "quickstrom";
unpackPhase = "true";
buildPhase = "";
nativeBuildInputs = [ pkgs.makeWrapper ];
installPhase = ''
mkdir -p $out/bin
makeWrapper "${haskellPackages.quickstrom-cli}/bin/quickstrom" \
$out/bin/quickstrom \
--set QUICKSTROM_LIBRARY_DIR "${dsl}" \
--set QUICKSTROM_HTML_REPORT_DIR "${html-report}" \
--set QUICKSTROM_CLIENT_SIDE_DIR "${client-side}"
'';
};
in { inherit haskellPackages quickstrom dsl client-side; }