blob: d869dd1813d7a4e552531e339219b3a7de327899 (
plain)
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
|
{ nixpkgs }:
with nixpkgs;
let
ghc = pkgs.haskell.packages.ghc844.ghcWithPackages (hp: with hp; [
hinotify
containers
directory
haskeline
HTTP
mtl
optparse-applicative
parsec
protolude
text
transformers
wl-pprint-text
]);
entrypoint = "Bs";
in
stdenv.mkDerivation rec {
name = "bs";
version = "0";
src = ../.;
nativeBuildInputs = [
ghc
];
strictDeps = true;
buildPhase = ''
${ghc}/bin/ghc \
-iapex -ilore \
-main-is ${entrypoint} --make apex/${entrypoint}.hs \
-o bild/${name}
'';
installPhase = ''
mkdir -p $out/bin
cp bild/${name} $out/bin/${name}
'';
}
|