@@ -37,31 +37,50 @@ dimension "Nixpkgs version" nixpkgsVersions (nixpkgsName: nixpkgs-pin:
3737 let pkgs = import pinnedNixpkgsSrc (nixpkgsArgs // { inherit system; });
3838 build = import ./build.nix { inherit pkgs ifdLevel; };
3939 platformFilter = platformFilterGeneric pkgs system;
40+ compilers = {
41+ inherit (pkgs.haskell-nix.compiler) ghc865 ghc883;
42+ };
4043 in filterAttrsOnlyRecursive (_: v: platformFilter v) {
4144 # Native builds
4245 # TODO: can we merge this into the general case by picking an appropriate "cross system" to mean native?
43− native = pkgs.recurseIntoAttrs {
46+ native = pkgs.recurseIntoAttrs ({
4447 inherit (build) tests tools maintainer-scripts maintainer-script-cache;
48+ ghc = pkgs.recurseIntoAttrs compilers;
49+ } // pkgs.lib.optionalAttrs (ifdLevel >= 1) {
50+ iserv-proxy = pkgs.recurseIntoAttrs (
51+ pkgs.lib.mapAttrs (ghcName: _:
52+ pkgs.ghc-extra-packages."${ghcName}".iserv-proxy.components.exes.iserv-proxy
53+ ) compilers);
54+ } // pkgs.lib.optionalAttrs (ifdLevel >= 2) {
4555 hello = (pkgs.haskell-nix.hackage-package { name = "hello"; version = "1.0.0.2"; }).components.exes.hello;
46− iserv-proxy = pkgs.ghc-extra-packages.ghc865.iserv-proxy.components.exes.iserv-proxy;
47− ghc = pkgs.recurseIntoAttrs pkgs.haskell-nix.compiler;
48− };
56+ });
4957 }
5058 //
5159 dimension "Cross system" (crossSystems nixpkgsName genericPkgs system) (crossSystemName: crossSystem:
5260 # Cross builds
5361 let pkgs = import pinnedNixpkgsSrc (nixpkgsArgs // { inherit system crossSystem; });
5462 build = import ./build.nix { inherit pkgs ifdLevel; };
55− in pkgs.recurseIntoAttrs {
63+ in pkgs.recurseIntoAttrs (pkgs.lib.optionalAttrs (ifdLevel >= 1) {
64+ ghc = pkgs.recurseIntoAttrs compilers;
5665 # TODO: look into making tools work when cross compiling
5766 # inherit (build) tools;
67+ } // pkgs.lib.optionalAttrs (ifdLevel >= 2) {
68+ remote-iserv = pkgs.recurseIntoAttrs (
69+ pkgs.lib.mapAttrs (ghcName: _:
70+ pkgs.ghc-extra-packages."${ghcName}".remote-iserv.components.exes.remote-iserv
71+ ) compilers);
72+ iserv-proxy = pkgs.recurseIntoAttrs (
73+ pkgs.lib.mapAttrs (ghcName: _:
74+ pkgs.ghc-extra-packages."${ghcName}".iserv-proxy.components.exes.iserv-proxy
75+ ) compilers);
76+ } // pkgs.lib.optionalAttrs (ifdLevel >= 3) {
5877 hello = (pkgs.haskell-nix.hackage-package { name = "hello"; version = "1.0.0.2"; }).components.exes.hello;
59− iserv-proxy = pkgs.ghc-extra-packages.ghc865.iserv-proxy.components.exes.iserv-proxy;
60− remote-iserv = pkgs.ghc-extra-packages.ghc865.remote-iserv.components.exes.remote-iserv;
6178 }
6279 //
6380 # Tests are broken on aarch64 cross https://github.com/input-output-hk/haskell.nix/issues/513
64− pkgs.lib.optionalAttrs (crossSystemName != "aarch64-multiplatform") { inherit (build) tests; }
81+ pkgs.lib.optionalAttrs (crossSystemName != "aarch64-multiplatform") {
82+ inherit (build) tests;
83+ })
6584 )
6685 )
6786)