Skip to content

Commit b206279

Browse files
committed
Merge remote-tracking branch 'origin/master' into fix-9.12-redistributable
2 parents e4e5336 + bc7a401 commit b206279

File tree

76 files changed

+277
-170
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

76 files changed

+277
-170
lines changed

build.nix

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ in rec {
2020
tests = import ./test/default.nix { inherit pkgs evalPackages ifdLevel compiler-nix-name; };
2121

2222
tools = pkgs.lib.optionalAttrs (ifdLevel >= 3) (
23-
pkgs.recurseIntoAttrs ({
23+
pkgs.lib.recurseIntoAttrs ({
2424
cabal-latest = tool compiler-nix-name "cabal" ({
2525
inherit evalPackages;
2626
} // pkgs.lib.optionalAttrs (ghcFromTo "9.13" "9.14") {
@@ -100,8 +100,8 @@ in rec {
100100

101101
# These are pure parts of maintainer-script so they can be built by hydra
102102
# and added to the cache to speed up buildkite.
103-
maintainer-script-cache = pkgs.recurseIntoAttrs (
104-
(pkgs.lib.optionalAttrs (pkgs.system == "x86_64-linux") {
103+
maintainer-script-cache = pkgs.lib.recurseIntoAttrs (
104+
(pkgs.lib.optionalAttrs (pkgs.stdenv.hostPlatform.system == "x86_64-linux") {
105105
inherit (maintainer-scripts) check-hydra;
106106
})
107107
// (pkgs.lib.optionalAttrs (ifdLevel > 2) {

builder/hspkg-builder.nix

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ let
6262

6363
in rec {
6464
components = haskellLib.applyComponents (buildComp pkg.allComponent) pkg;
65-
checks = pkgs.recurseIntoAttrs (builtins.mapAttrs
65+
checks = pkgs.lib.recurseIntoAttrs (builtins.mapAttrs
6666
(_: d: haskellLib.check d)
6767
(lib.filterAttrs (_: d: d.config.doCheck) components.tests));
6868
inherit (package) identifier detailLevel isLocal isProject buildType;

ci.nix

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
# short names for nixpkgs versions
2020
nixpkgsVersions = {
21-
"R2505" = inputs.nixpkgs-2505;
21+
"R2511" = inputs.nixpkgs-2511;
2222
"unstable" = inputs.nixpkgs-unstable;
2323
};
2424

@@ -64,12 +64,10 @@
6464
# cabal-install and nix-tools plans. When removing a ghc version
6565
# from here (so that is no longer cached) also remove ./materialized/ghcXXX.
6666
# Update supported-ghc-versions.md to reflect any changes made here.
67-
nixpkgs.lib.optionalAttrs (builtins.elem nixpkgsName ["R2411" "R2505"]) {
67+
nixpkgs.lib.optionalAttrs (builtins.elem nixpkgsName ["R2411" "R2505" "R2511"]) {
6868
ghc96 = false;
6969
ghc98 = false;
70-
ghc98llvm = false;
7170
ghc910 = false;
72-
ghc910llvm = false;
7371
ghc912 = false;
7472
} // nixpkgs.lib.optionalAttrs (nixpkgsName == "unstable") {
7573
ghc96 = true;
@@ -93,7 +91,7 @@
9391
inherit (lib.systems.examples) ghcjs;
9492
} // lib.optionalAttrs (nixpkgsName == "unstable"
9593
&& (__match ".*llvm" compiler-nix-name == null)
96-
&& !builtins.elem compiler-nix-name ["ghc967" "ghc984" "ghc9102" "ghc9103"]
94+
&& !builtins.elem compiler-nix-name ["ghc967" "ghc984" "ghc9103"]
9795
&& system != "x86_64-darwin") {
9896
inherit (lib.systems.examples) wasi32;
9997
} // lib.optionalAttrs (nixpkgsName == "unstable"
@@ -113,9 +111,12 @@
113111
} // lib.optionalAttrs (__match ".*llvm" compiler-nix-name == null && system == "x86_64-linux" && nixpkgsName == "unstable" && !builtins.elem compiler-nix-name ["ghc902" "ghc928" "ghc948"]) {
114112
# Out llvm versions of GHC seem to break for musl32
115113
inherit (lib.systems.examples) musl32;
116-
} // lib.optionalAttrs (system == "x86_64-linux" && !builtins.elem compiler-nix-name ["ghc902" "ghc928" "ghc948"]) {
114+
} // lib.optionalAttrs (system == "x86_64-linux"
115+
&& !builtins.elem compiler-nix-name ["ghc967" "ghc984" "ghc9103"]) {
117116
inherit (lib.systems.examples) aarch64-android-prebuilt;
118-
} // lib.optionalAttrs (system == "x86_64-linux" && nixpkgsName != "unstable" && !builtins.elem compiler-nix-name ["ghc902" "ghc928" "ghc948" "ghc9103" "ghc9103llvm" "ghc91320250523"]) {
117+
} // lib.optionalAttrs (system == "x86_64-linux"
118+
&& nixpkgsName != "unstable"
119+
&& !builtins.elem compiler-nix-name ["ghc967" "ghc984" "ghc9103" "ghc91320250523"]) {
119120
inherit (lib.systems.examples) armv7a-android-prebuilt;
120121
} // lib.optionalAttrs (system == "x86_64-linux" && nixpkgsName == "unstable" && !builtins.elem compiler-nix-name ["ghc8107" "ghc902"]) {
121122
# TODO fix this for the compilers we build with hadrian (ghc >=9.4)
@@ -134,7 +135,7 @@ dimension "Nixpkgs version" nixpkgsVersions (nixpkgsName: pinnedNixpkgsSrc:
134135
in filterAttrsOnlyRecursive (_: v: platformFilter v && !(isDisabled v)) ({
135136
# Native builds
136137
# TODO: can we merge this into the general case by picking an appropriate "cross system" to mean native?
137-
native = pkgs.recurseIntoAttrs ({
138+
native = pkgs.lib.recurseIntoAttrs ({
138139
roots = pkgs.haskell-nix.roots' { inherit compiler-nix-name evalPackages; } ifdLevel;
139140
} // pkgs.lib.optionalAttrs runTests {
140141
inherit (build) tests tools maintainer-scripts maintainer-script-cache;
@@ -156,7 +157,7 @@ dimension "Nixpkgs version" nixpkgsVersions (nixpkgsName: pinnedNixpkgsSrc:
156157
then import pinnedNixpkgsSrc (nixpkgsArgs // { inherit system crossSystem; })
157158
else crossSystem (import pinnedNixpkgsSrc (nixpkgsArgs // { inherit system; }));
158159
build = import ./build.nix { inherit pkgs evalPackages ifdLevel compiler-nix-name haskellNix; };
159-
in pkgs.recurseIntoAttrs (pkgs.lib.optionalAttrs (ifdLevel >= 1) ({
160+
in pkgs.lib.recurseIntoAttrs (pkgs.lib.optionalAttrs (ifdLevel >= 1) ({
160161
roots = pkgs.haskell-nix.roots' { inherit compiler-nix-name evalPackages; } ifdLevel // {
161162
ghc = pkgs.buildPackages.haskell-nix.compiler.${compiler-nix-name}.override { ghcEvalPackages = evalPackages; };
162163
};

default.nix

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,9 @@ self // {
100100
pkgs-2505 = import self.inputs.nixpkgs-2505 (nixpkgsArgs // {
101101
localSystem = { inherit system; };
102102
});
103+
pkgs-2511 = import self.inputs.nixpkgs-2511 (nixpkgsArgs // {
104+
localSystem = { inherit system; };
105+
});
103106
pkgs-unstable = import self.inputs.nixpkgs-unstable (nixpkgsArgs // {
104107
localSystem = { inherit system; };
105108
});

flake.lock

Lines changed: 32 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
nixpkgs-2405 = { url = "github:NixOS/nixpkgs/nixpkgs-24.05-darwin"; };
99
nixpkgs-2411 = { url = "github:NixOS/nixpkgs/nixpkgs-24.11-darwin"; };
1010
nixpkgs-2505 = { url = "github:NixOS/nixpkgs/nixpkgs-25.05-darwin"; };
11+
nixpkgs-2511 = { url = "github:NixOS/nixpkgs/nixpkgs-25.11-darwin"; };
1112
nixpkgs-unstable = { url = "github:NixOS/nixpkgs/nixpkgs-unstable"; };
1213
flake-compat = { url = "github:input-output-hk/flake-compat/hkm/gitlab-fix"; flake = false; };
1314
"hls-1.10" = { url = "github:haskell/haskell-language-server/1.10.0.0"; flake = false; };

lib/default.nix

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
{ pkgs, stdenv, lib, haskellLib, recurseIntoAttrs, srcOnly }:
1+
{ pkgs, stdenv, lib, haskellLib, srcOnly }:
22

33

44
with haskellLib;
@@ -166,7 +166,7 @@ in {
166166
components =
167167
if lib.isDerivation components || components == {}
168168
then components
169-
else recurseIntoAttrs components;
169+
else lib.recurseIntoAttrs components;
170170
};
171171
packageFilter = _name: package: (package.isHaskell or false) && packageSel package;
172172
filteredPkgs = lib.filterAttrs packageFilter haskellPackages;
@@ -177,7 +177,7 @@ in {
177177
lib.filterAttrs (_: components: components != {}) (
178178
builtins.mapAttrs (_name: packages:
179179
builtins.foldl' (a: b: a // b) {} (map (x: x.components) packages)) packagesGroupedByName);
180-
in recurseIntoAttrs combined;
180+
in lib.recurseIntoAttrs combined;
181181

182182
# Equivalent to collectComponents with (_: true) as selection function.
183183
# Useful for pre-filtered package-set.
@@ -193,7 +193,7 @@ in {
193193
# This can be used to collect all the test runs in your project, so that can be run in CI.
194194
collectChecks = packageSel: haskellPackages:
195195
let packageFilter = _name: package: (package.isHaskell or false) && packageSel package;
196-
in recurseIntoAttrs (lib.filterAttrs (_: x: x != {} && x != recurseIntoAttrs {}) (lib.mapAttrs (_: p: p.checks) (lib.filterAttrs packageFilter haskellPackages)));
196+
in lib.recurseIntoAttrs (lib.filterAttrs (_: x: x != {} && x != lib.recurseIntoAttrs {}) (lib.mapAttrs (_: p: p.checks) (lib.filterAttrs packageFilter haskellPackages)));
197197

198198
# Equivalent to collectChecks with (_: true) as selection function.
199199
# Useful for pre-filtered package-set.

modules/install-plan/redirect.nix

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ let
3939
// lib.optionalAttrs (componentsByName ? lib) {
4040
library = lookupComponent "" "" componentsByName.lib;
4141
};
42-
checks = pkgs.recurseIntoAttrs (
42+
checks = pkgs.lib.recurseIntoAttrs (
4343
lib.filterAttrs (_: x: x != {}) (
4444
builtins.mapAttrs
4545
(_: d: pkgs.haskell-nix.haskellLib.check d)

modules/project-common.nix

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ with lib.types;
4343
};
4444
evalSystem = mkOption {
4545
type = str;
46-
default = pkgs.pkgsBuildBuild.stdenv.system;
46+
default = pkgs.pkgsBuildBuild.stdenv.hostPlatform.system;
4747
description = ''
4848
Specifies the system on which `cabal` and `nix-tools` should run.
4949
If not specified the `pkgsBuildBuild` system will be used.
@@ -55,7 +55,7 @@ with lib.types;
5555
evalPackages = mkOption {
5656
type = attrs;
5757
default =
58-
if pkgs.pkgsBuildBuild.stdenv.system == config.evalSystem
58+
if pkgs.pkgsBuildBuild.stdenv.hostPlatform.system == config.evalSystem
5959
then pkgs.pkgsBuildBuild
6060
else
6161
import pkgs.path {

nix-tools/flake.nix

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
pkgs'.nix-tools-set { compilerSelection = lib.mkForce (p: p.haskell-nix.compiler); };
3030

3131
# tarball filename e.g. nix-tools-0.1.0.0-x86_64-unknown-linux-musl.tar.gz
32-
tarball-filename = "${toolset.name}-${pkgs.hostPlatform.config}.tar.gz";
32+
tarball-filename = "${toolset.name}-${pkgs.stdenv.hostPlatform.config}.tar.gz";
3333
in
3434
pkgs.runCommand tarball-filename
3535
{ preferLocalBuild = true; }
@@ -80,13 +80,13 @@
8080
# project's hydraJobs
8181
pkgs.nix-tools-eval-on-linux.project.flake'.hydraJobs
8282
# tarballs with static builds.
83-
// lib.optionalAttrs (pkgs.buildPlatform.system == "x86_64-linux")
83+
// lib.optionalAttrs (pkgs.stdenv.buildPlatform.system == "x86_64-linux")
8484
{ binary-tarball = mkTarball pkgs.pkgsCross.musl64; }
8585
# aarch64-multiplatform-musl cross compile is currently broken
86-
# // lib.optionalAttrs (pkgs.buildPlatform.system == "aarch64-linux")
86+
# // lib.optionalAttrs (pkgs.stdenv.buildPlatform.system == "aarch64-linux")
8787
# { binary-tarball = mkTarball pkgs.pkgsCross.aarch64-multiplatform-musl; }
8888
// {
89-
static = static-nix-tools-outputs.hydraJobs.${pkgs.system};
89+
static = static-nix-tools-outputs.hydraJobs.${pkgs.stdenv.hostPlatform.system};
9090
}
9191
);
9292
};

0 commit comments

Comments
 (0)