diff options
author | Ben Sima <ben@bsima.me> | 2021-06-10 08:14:16 -0400 |
---|---|---|
committer | Ben Sima <ben@bsima.me> | 2021-11-26 13:47:35 -0500 |
commit | 72a7aaa39e7552970f466e712e1f7ef91aeb03c8 (patch) | |
tree | 8b8d501d28a9c1d56a0150d8129ff6324f196ad9 /Biz/Bild.nix | |
parent | 0ff0a23c8c7425b0d56b95e318c2087e74cb6605 (diff) |
Upgrade to nixos-21.05
Getting me closer to the latest GHC. This release also includes my own packages
that I submitted some time ago.
GHCJS is not present in 21.05 for some reason, but I think it's back in master,
so I might do another upgrade soon, but for now I just disabled my GHCJS
support. I'm not really using it anyway.
I also had to bring it string-quote, update nixos-mailserver, and a few other
things.
Diffstat (limited to 'Biz/Bild.nix')
-rw-r--r-- | Biz/Bild.nix | 77 |
1 files changed, 39 insertions, 38 deletions
diff --git a/Biz/Bild.nix b/Biz/Bild.nix index 44c500a..bcb1940 100644 --- a/Biz/Bild.nix +++ b/Biz/Bild.nix @@ -3,7 +3,7 @@ with nixpkgs; let - ghcCompiler = "ghc865"; + ghcCompiler = "ghc884"; ghcjsCompiler = "ghcjs86"; # provided by .envrc @@ -26,7 +26,7 @@ let haskellDeps = hpkgs: import ./Bild/Deps/Haskell.nix hpkgs; mkGhcPackageSet = pkgs.haskell.packages.${ghcCompiler}.ghcWithHoogle; - mkGhcjsPackageSet = pkgs.haskell.packages.${ghcjsCompiler}.ghcWithPackages; + #mkGhcjsPackageSet = pkgs.haskell.packages.${ghcjsCompiler}.ghcWithPackages; in rec { # gather data needed for compiling by analyzing the main module @@ -87,30 +87,30 @@ in rec { installPhase = "exit 0"; } // { env = ghc; }; - ghcjs = main: - let - data = analyze main; - ghcjs = mkGhcjsPackageSet (hp: selectAttrs data.deps hp); - in stdenv.mkDerivation { - name = data.module; - src = ../.; - nativeBuildInputs = [ ghcjs ]; - strictDeps = true; - buildPhase = '' - mkdir -p $out/static - # compile with ghcjs - ${ghcjs}/bin/ghcjs \ - -Werror \ - -i. \ - --make ${main} \ - -main-is ${data.module} \ - -o ${data.out} - # optimize js output - ${pkgs.closurecompiler}/bin/closure-compiler \ - ${data.out}/all.js > $out/static/${data.out} - ''; - installPhase = "exit 0"; - } // { env = ghcjs; }; + #ghcjs = main: + # let + # data = analyze main; + # ghcjs = mkGhcjsPackageSet (hp: selectAttrs data.deps hp); + # in stdenv.mkDerivation { + # name = data.module; + # src = ../.; + # nativeBuildInputs = [ ghcjs ]; + # strictDeps = true; + # buildPhase = '' + # mkdir -p $out/static + # # compile with ghcjs + # ${ghcjs}/bin/ghcjs \ + # -Werror \ + # -i. \ + # --make ${main} \ + # -main-is ${data.module} \ + # -o ${data.out} + # # optimize js output + # ${pkgs.closurecompiler}/bin/closure-compiler \ + # ${data.out}/all.js > $out/static/${data.out} + # ''; + # installPhase = "exit 0"; + # } // { env = ghcjs; }; env = mkShell { name = "bizdev"; @@ -118,18 +118,17 @@ in rec { # haskell deps (mkGhcPackageSet haskellDeps) # ghcjs doesn't need everything, and many things fail to build - (mkGhcjsPackageSet (hp: with hp; [ - aeson - clay - containers - miso - protolude - servant - split - string-quote - text - ghcjs-base - ])) + #(mkGhcjsPackageSet (hp: with hp; [ + # aeson + # clay + # containers + # miso + # protolude + # servant + # split + # text + # ghcjs-base + #])) # python deps (nixpkgs.python38.withPackages (p: @@ -164,4 +163,6 @@ in rec { }; os = cfg: (nixos (args: cfg)).toplevel; + + sources = nixpkgs.sources; } |