From df51960570d60479995f247ad3d8a98db79d8d50 Mon Sep 17 00:00:00 2001 From: Alyssa Ross Date: Mon, 19 Feb 2024 01:36:25 +0100 Subject: [PATCH 1/2] pkgsStatic.elfutils: mark unsupported It's more accurate to say this is unsupported than broken. (But it wasn't possible to do that at the time the broken mark was added.) --- pkgs/development/tools/misc/elfutils/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/tools/misc/elfutils/default.nix b/pkgs/development/tools/misc/elfutils/default.nix index d61cf961615f..0533af678919 100644 --- a/pkgs/development/tools/misc/elfutils/default.nix +++ b/pkgs/development/tools/misc/elfutils/default.nix @@ -93,7 +93,7 @@ stdenv.mkDerivation rec { description = "A set of utilities to handle ELF objects"; platforms = platforms.linux; # https://lists.fedorahosted.org/pipermail/elfutils-devel/2014-November/004223.html - broken = stdenv.hostPlatform.isStatic; + badPlatforms = [ lib.systems.inspect.platformPatterns.isStatic ]; # licenses are GPL2 or LGPL3+ for libraries, GPL3+ for bins, # but since this package isn't split that way, all three are listed. license = with licenses; [ gpl2Only lgpl3Plus gpl3Plus ]; From f60a899000755c4c909799bbbd192e9a212b37c6 Mon Sep 17 00:00:00 2001 From: Alyssa Ross Date: Mon, 19 Feb 2024 01:37:06 +0100 Subject: [PATCH 2/2] pkgsStatic.strace: fix build Static-only elfutils builds are not supported. Fixes: a48232a475ff ("strace: 6.6 -> 6.7") --- pkgs/development/tools/misc/strace/default.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkgs/development/tools/misc/strace/default.nix b/pkgs/development/tools/misc/strace/default.nix index d851aa217b5f..5dc67a627a55 100644 --- a/pkgs/development/tools/misc/strace/default.nix +++ b/pkgs/development/tools/misc/strace/default.nix @@ -12,9 +12,12 @@ stdenv.mkDerivation rec { depsBuildBuild = [ buildPackages.stdenv.cc ]; nativeBuildInputs = [ perl ]; + # libunwind for -k. # On RISC-V platforms, LLVM's libunwind implementation is unsupported by strace. # The build will silently fall back and -k will not work on RISC-V. - buildInputs = [ libunwind elfutils ]; # support -k and -kk + buildInputs = [ libunwind ] + # -kk + ++ lib.optional (lib.meta.availableOn stdenv.hostPlatform elfutils) elfutils; configureFlags = [ "--enable-mpers=check" ];