-
-
Notifications
You must be signed in to change notification settings - Fork 14.4k
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
Fix cross eval issues #362546
Fix cross eval issues #362546
Conversation
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.
Python changes look fine. Could use python27 for one less indirection.
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.
I like @mweinelt's suggestion about python2
-> python27
.
376de9c
to
9245a60
Compare
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.
Lgtm % @sternenseemann saying yes
53e61be
to
905d1b8
Compare
905d1b8
to
afb33a2
Compare
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.
Latest changes look good to me.
afb33a2
to
7e6ef49
Compare
https://www.github.com/NixOS/nixpkgs/issues/362272 Fixes ``` $ nix repl --file . --system aarch64-darwin nix-repl> pkgsCross.aarch64-multiplatform.haskellPackages.ghc-lib.env error: … while evaluating attribute 'LOCALE_ARCHIVE' of derivation 'ghc-shell-for-ghc-lib-aarch64-unknown-linux-gnu-9.6.6.20240701-aarch64-unknown-linux-gnu' error: cannot coerce null to a string: null ```
`throw`s are better because they don't abort evaluation when evaluating the whole set. Fixes `error: evaluation aborted with the following error message: 'Unsupported platform: arm64.'` on linux cross from darwin
1c386fd
to
8d0daf6
Compare
Don't fail with a missing attribute error, so the error can be handled.
…cross eval Release eval fails with ``` nix-env failed: trace: evaluation warning: cannot enable SNMP support due to cross-compilation issues with net-snmp-config ```
8d0daf6
to
eddbb62
Compare
|
In https://www.github.com/NixOS/nixpkgs/pull/341067 `ofborg-eval-lib-tests` fails because it uses `pkgsHostTarget` of the cross pkgs ```diff diff --git a/pkgs/top-level/impure.nix b/pkgs/top-level/impure.nix index 4d847e280f4b..7f0099b254f0 100644 --- a/pkgs/top-level/impure.nix +++ b/pkgs/top-level/impure.nix @@ -86,4 +86,6 @@ assert args ? system -> !(args ? localSystem); import ./. (builtins.removeAttrs args [ "system" ] // { inherit config overlays localSystem; -}) +} // (if ((localSystem.system or localSystem) == "x86_64-linux" || (localSystem.system or localSystem) == "aarch64-linux") then { + crossSystem = { config = "aarch64-unknown-linux-gnu"; }; + } else {}) ) ```
Dunno if this is correct, there's other `hostPlatform.isDarwin` conditionals which may be wrong. Leaving the other conditionals to swift maintainers or people who are interested in swift cross-compilation ``` $ nix repl --file . --system aarch64-darwin nix-repl> pkgsCross.aarch64-multiplatform.swift «derivation /nix/store/kqbaqwdfc9g0yvkq4ffrlqspranprlmy-swift-wrapper-aarch64-unknown-linux-gnu-5.8.drv» nix-repl> pkgsCross.aarch64-multiplatform.buildPackages.swift error: error: expected a string but found null: null at /home/artturin/nixgits/my-nixpkgs/.worktree/2/pkgs/development/compilers/swift/compiler/default.nix:586:11: 585| #WATCHOS_SIMULATOR 586| }.${targetPlatform.darwinPlatform}} | ^ 587| ```
Added comment to release.nix and updated the patch in the commit msg |
eddbb62
to
276fe40
Compare
Split from #341067
Exposed by https://github.com/NixOS/nixpkgs/commit/bd32adb9e8452e96f7dbb5ee0bebd96bab0ea320.patch
https://github.com/NixOS/nixpkgs/commit/6761b8e2ff4861cd5f371ebb2753ec547078221d.patch
Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.