From 63fa1fcb043dc1da18254749672520dbcc8953b5 Mon Sep 17 00:00:00 2001 From: Shea Levy Date: Sat, 24 Feb 2018 10:37:54 -0500 Subject: [PATCH] kexectools: Only build on kexecable architectures. --- lib/systems/inspect.nix | 3 +++ pkgs/top-level/all-packages.nix | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/systems/inspect.nix b/lib/systems/inspect.nix index 0fce5254dcb4..45c9360cc0f7 100644 --- a/lib/systems/inspect.nix +++ b/lib/systems/inspect.nix @@ -35,6 +35,9 @@ rec { MinGW = { kernel = kernels.windows; abi = abis.gnu; }; Musl = with abis; map (a: { abi = a; }) [ musl musleabi musleabihf ]; + + Kexecable = map (family: { kernel = kernels.linux; cpu.family = family; }) + [ "x86" "arm" "aarch64" "mips" ]; }; matchAnyAttrs = patterns: diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 70fcf54883a2..bc416c4052a6 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -3063,7 +3063,9 @@ with pkgs; keepalived = callPackage ../tools/networking/keepalived { }; - kexectools = callPackage ../os-specific/linux/kexectools { }; + kexectools = if hostPlatform.isKexecable + then callPackage ../os-specific/linux/kexectools { } + else null; keybase = callPackage ../tools/security/keybase { };