@@ -1,9 +1,7 @@
1with (import <nixpkgs> {});
2with (import <nixpkgs> {});
4− # MUST match GHC of resolver in stack.yaml
5− ghc = haskell.packages.ghc802.ghc;
7 native_libs = [
5 native_libs = [
@@ -15,17 +13,9 @@ let
15 CoreServices
13 CoreServices
18−in stdenv.mkDerivation {
16+in haskell.lib.buildStackProject {
18+ buildInputs = native_libs;
20 name = "idrisBuildEnv";
19 name = "idrisBuildEnv";
22− buildInputs = [ ghc ] ++ native_libs;
24− STACK_IN_NIX_EXTRA_ARGS = builtins.foldl'
26− " --extra-lib-dirs=${lib}/lib --extra-include-dirs=${lib}/include" + acc)
29− # Needed if one wants to use ghci, due to https://ghc.haskell.org/trac/ghc/ticket/11042
30− LD_LIBRARY_PATH = builtins.concatStringsSep ":" (map (lib: lib.out + "/lib") native_libs);