summaryrefslogtreecommitdiffstats
path: root/pkgs/test/default.nix
diff options
context:
space:
mode:
authorRobert Hensing <robert@roberthensing.nl>2023-01-23 19:08:46 +0100
committerRobert Hensing <robert@roberthensing.nl>2023-01-29 09:51:54 +0100
commite93cfb250b683f3ffd9adc957c14b5b3b2e108ae (patch)
tree89c7189d24506c225283980417cc86c72ed785d9 /pkgs/test/default.nix
parent7790eafbdcbc85a8e48912189400565dd039cb64 (diff)
tests.pkg-configPackages: Filter out unsupported packages
Diffstat (limited to 'pkgs/test/default.nix')
-rw-r--r--pkgs/test/default.nix17
1 files changed, 16 insertions, 1 deletions
diff --git a/pkgs/test/default.nix b/pkgs/test/default.nix
index 8ff0e163395f..82134b051d4e 100644
--- a/pkgs/test/default.nix
+++ b/pkgs/test/default.nix
@@ -51,7 +51,22 @@ with pkgs;
php = recurseIntoAttrs (callPackages ./php {});
- pkg-configPackages = callPackage ./pkg-config-packages.nix { };
+ pkg-configPackages =
+ let
+ # pkg-configPackages test needs a Nixpkgs with allowUnsupportedPlatform
+ # in order to filter out the unsupported packages without throwing any errors
+ # tryEval would be too fragile, masking different problems as if they're
+ # unsupported platform problems.
+ allPkgs = import ../top-level {
+ system = pkgs.stdenv.hostPlatform.system;
+ localSystem = pkgs.stdenv.hostPlatform.system;
+ config = {
+ allowUnsupportedSystem = true;
+ };
+ overlays = [];
+ };
+ in
+ allPkgs.callPackage ./pkg-config-packages.nix { };
rustCustomSysroot = callPackage ./rust-sysroot {};
buildRustCrate = callPackage ../build-support/rust/build-rust-crate/test { };