-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
pkgs/top-level/release.nix: enable pkgsLLVM #330567
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
d3a26a4
8a0da10
18ca929
f30794e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -9,6 +9,7 @@ | |
| myChunk, | ||
| checkMeta, | ||
| includeBroken, | ||
| includeSubpackages, | ||
| systems, | ||
| }: | ||
|
|
||
|
|
@@ -18,7 +19,12 @@ let | |
|
|
||
| unfiltered = import ./release-outpaths.nix { | ||
| inherit path; | ||
| inherit checkMeta includeBroken systems; | ||
| inherit | ||
| checkMeta | ||
| includeBroken | ||
| includeSubpackages | ||
| systems | ||
| ; | ||
|
||
| }; | ||
|
|
||
| # Turns the unfiltered recursive attribute set into one that is limited to myAttrpaths | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -69,6 +69,7 @@ let | |
| id | ||
| isDerivation | ||
| optionals | ||
| subtractLists | ||
| ; | ||
|
|
||
| inherit (release-lib.lib.attrsets) unionOfDisjoint; | ||
|
|
@@ -320,6 +321,8 @@ let | |
| jobs = let | ||
| packagePlatforms = release-lib.recursiveMapPackages | ||
| (if attrNamesOnly then id else release-lib.getPlatforms); | ||
| packagePlatformsExclude = systems: release-lib.recursiveMapPackages | ||
| (if attrNamesOnly then id else (drv: subtractLists (release-lib.getPlatforms drv) systems)); | ||
| packageJobs = packagePlatforms pkgs // { | ||
| haskell.compiler = packagePlatforms pkgs.haskell.compiler; | ||
| haskellPackages = packagePlatforms pkgs.haskellPackages; | ||
|
|
@@ -340,7 +343,7 @@ let | |
| idrisPackages = packagePlatforms pkgs.idrisPackages; | ||
| agdaPackages = packagePlatforms pkgs.agdaPackages; | ||
|
|
||
| pkgsLLVM.stdenv = [ "x86_64-linux" "aarch64-linux" ]; | ||
| pkgsLLVM = packagePlatformsExclude [ "aarch64-darwin" "x86_64-darwin" ] pkgs.pkgsLLVM; | ||
|
||
| pkgsArocc.stdenv = [ "x86_64-linux" "aarch64-linux" ]; | ||
| pkgsZig.stdenv = [ "x86_64-linux" "aarch64-linux" ]; | ||
| pkgsMusl.stdenv = [ "x86_64-linux" "aarch64-linux" ]; | ||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -175,6 +175,10 @@ let | |||||||||||
| lib.optionalAttrs allowCustomOverrides | ||||||||||||
| ((config.packageOverrides or (super: {})) super); | ||||||||||||
|
|
||||||||||||
| nixpkgsFunSub = attrs: nixpkgsFun (attrs // { | ||||||||||||
| allowHydra = config.allowHydraSubpackages; | ||||||||||||
| }); | ||||||||||||
|
|
||||||||||||
| # Convenience attributes for instantitating package sets. Each of | ||||||||||||
| # these will instantiate a new version of allPackages. Currently the | ||||||||||||
| # following package sets are provided: | ||||||||||||
|
|
@@ -192,7 +196,7 @@ let | |||||||||||
| nixpkgsFun { inherit crossSystem; }) | ||||||||||||
| lib.systems.examples; | ||||||||||||
|
|
||||||||||||
| pkgsLLVM = nixpkgsFun { | ||||||||||||
| pkgsLLVM = if stdenv.hostPlatform.isDarwin then self else nixpkgsFunSub { | ||||||||||||
|
||||||||||||
| pkgsLLVM = if stdenv.hostPlatform.isDarwin then self else nixpkgsFunSub { | |
| pkgsLLVM = nixpkgsFun { | |
| config = { eval = true; hydra = false; }; | |
| ... | |
| } |
Thus we could define those properties in exactly one location - right where we define the package set.
And then everything else should just work off of that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The problem is some attributes in CUDA disappears in Darwin which causes Darwin evals to fail. From a UX perspective, this looks better but practically this is a harder problem to solve.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Those checks are related to pkgsLLVM specifically, so I think it's the wrong place to put this knowledge.
Assume we are going to add e.g. pkgsStatic eventually, too - we might need different conditions here.
Is this even needed with the "if darwin then self" check you currently have in
stage.nix?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The problem is I need to disable eval for Darwin but checking if it's for Darwin isn't as simple as it looks.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's what I was questioning. With this line:
eval should succeed on darwin, right?
In fact, it should just refer to the same attributes as on the top-level, so eval on darwin should be a no-op? What am I missing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, it complains about missing attributes and fails to eval Darwin.