-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathdefault.nix
23 lines (21 loc) · 829 Bytes
/
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
{ ghcVersion ? "ghc865"
, misoPkgs ? import (builtins.fetchTarball {
url = "https://github.com/dmjio/miso/archive/561ffad.tar.gz";
sha256 = "1wwzckz2qxb873wdkwqmx9gmh0wshcdxi7gjwkba0q51jnkfdi41";
}) {}
}:
with misoPkgs.pkgs;
with haskell.packages."${ghcVersion}";
let runtimeDeps = [ nwjs ];
app = callCabal2nix "haskell-editor-setup" ./. { miso = miso-jsaddle; };
in
app.overrideAttrs (old: {
miso = miso-jsaddle;
# needs nw in RPATH in order to use propagatedBuildInputs -> useless for runtime
buildInputs = old.buildInputs ++ [ binutils makeWrapper ];
postFixup = ''
mv $out/bin/haskell-editor-setup $out/bin/.haskell-editor-setup-wrapped
makeWrapper $out/bin/.haskell-editor-setup-wrapped $out/bin/haskell-editor-setup \
--prefix PATH : ${lib.makeBinPath runtimeDeps}
'';
})