on iko/ghcjs-patch-master help sign in
Remove propagatedBuildInputs from ghc (#1318)
01db382Cheng Shao
compiler/ghc/configured-src.nix+3−3
@@ -33,9 +33,6 @@ stdenv.mkDerivation (rec {
33
33
34 buildInputs = [ perl bash ] ++ (libDeps hostPlatform);
34 buildInputs = [ perl bash ] ++ (libDeps hostPlatform);
35
35
36− propagatedBuildInputs = [ targetPackages.stdenv.cc ]
37− ++ lib.optional useLLVM llvmPackages.llvm;
38−
39 depsTargetTarget = map lib.getDev (libDeps targetPlatform);
36 depsTargetTarget = map lib.getDev (libDeps targetPlatform);
40 depsTargetTargetPropagated = map (lib.getOutput "out") (libDeps targetPlatform);
37 depsTargetTargetPropagated = map (lib.getOutput "out") (libDeps targetPlatform);
41
38
@@ -65,6 +62,9 @@ stdenv.mkDerivation (rec {
65
62
66 echo -n "${buildMK}" > mk/build.mk
63 echo -n "${buildMK}" > mk/build.mk
67 sed -i -e 's|-isysroot /Developer/SDKs/MacOSX10.5.sdk||' configure
64 sed -i -e 's|-isysroot /Developer/SDKs/MacOSX10.5.sdk||' configure
65+ '' + lib.optionalString useLLVM ''
66+ export LLC="${llvmPackages.llvm}/bin/llc"
67+ export OPT="${llvmPackages.llvm}/bin/opt"
68 '' + lib.optionalString (!stdenv.isDarwin) ''
68 '' + lib.optionalString (!stdenv.isDarwin) ''
69 export NIX_LDFLAGS+=" -rpath $out/lib/${targetPrefix}ghc-${version}"
69 export NIX_LDFLAGS+=" -rpath $out/lib/${targetPrefix}ghc-${version}"
70 '' + lib.optionalString stdenv.isDarwin ''
70 '' + lib.optionalString stdenv.isDarwin ''
compiler/ghc/default.nix−3
@@ -234,9 +234,6 @@ stdenv.mkDerivation (rec {
234
234
235 buildInputs = [ perl bash ] ++ (libDeps hostPlatform);
235 buildInputs = [ perl bash ] ++ (libDeps hostPlatform);
236
236
237− propagatedBuildInputs = [ targetPackages.stdenv.cc ]
238− ++ lib.optional useLLVM llvmPackages.llvm;
239−
240 depsTargetTarget = map lib.getDev (libDeps targetPlatform);
237 depsTargetTarget = map lib.getDev (libDeps targetPlatform);
241 depsTargetTargetPropagated = map (lib.getOutput "out") (libDeps targetPlatform);
238 depsTargetTargetPropagated = map (lib.getOutput "out") (libDeps targetPlatform);
242
239
lib/ghcjs-project.nix+3−4
@@ -76,7 +76,7 @@ let
76 # Inputs needed to boot the GHCJS compiler
76 # Inputs needed to boot the GHCJS compiler
77 bootInputs = with pkgs.buildPackages; [
77 bootInputs = with pkgs.buildPackages; [
78 # pin nodejs to the 12 series for now, as strings can only be half the length in node 14+
78 # pin nodejs to the 12 series for now, as strings can only be half the length in node 14+
79− # see https://github.com/nodejs/node/issues/33960, this can break large TH splices for now.
79+ # see https://github.com/nodejs/node/issues/33960, this can break large TH splices for now.
80 nodejs-12_x
80 nodejs-12_x
81 makeWrapper
81 makeWrapper
82 xorg.lndir
82 xorg.lndir
@@ -85,7 +85,7 @@ let
85 ]
85 ]
86 ++ [ ghc cabal-install emsdk ];
86 ++ [ ghc cabal-install emsdk ];
87 # Configured the GHCJS source
87 # Configured the GHCJS source
88− configured-src = pkgs.runCommand "configured-ghcjs-src" {
88+ configured-src = pkgs.runCommandCC "configured-ghcjs-src" {
89 buildInputs = configureInputs;
89 buildInputs = configureInputs;
90 inherit src;
90 inherit src;
91 } ''
91 } ''
@@ -132,7 +132,7 @@ let
132 # see https://github.com/ghcjs/ghcjs/issues/751 for the happy upper bound.
132 # see https://github.com/ghcjs/ghcjs/issues/751 for the happy upper bound.
133
133
134 ghcjsProject = pkgs.haskell-nix.cabalProject' (
134 ghcjsProject = pkgs.haskell-nix.cabalProject' (
135− (pkgs.lib.filterAttrs
135+ (pkgs.lib.filterAttrs
136 (n: _: !(builtins.any (x: x == n)
136 (n: _: !(builtins.any (x: x == n)
137 ["src" "ghcjsVersion" "ghcVersion" "happy" "alex" "cabal-install"])) args) // {
137 ["src" "ghcjsVersion" "ghcVersion" "happy" "alex" "cabal-install"])) args) // {
138 src = configured-src;
138 src = configured-src;
@@ -187,4 +187,3 @@ in ghcjsProject // {
187 };
187 };
188 inherit configureInputs bootInputs configured-src emscriptenupstream emscripten emsdk;
188 inherit configureInputs bootInputs configured-src emscriptenupstream emscripten emsdk;
189}
189}
190−