summary refs log tree commit diff
path: root/pkgs/development/tools/misc/elfutils/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/tools/misc/elfutils/default.nix')
-rw-r--r--pkgs/development/tools/misc/elfutils/default.nix14
1 files changed, 10 insertions, 4 deletions
diff --git a/pkgs/development/tools/misc/elfutils/default.nix b/pkgs/development/tools/misc/elfutils/default.nix
index 56bfe26ec06..4ad7f830066 100644
--- a/pkgs/development/tools/misc/elfutils/default.nix
+++ b/pkgs/development/tools/misc/elfutils/default.nix
@@ -1,13 +1,13 @@
-{ lib, stdenv, fetchurl, m4, zlib, bzip2, bison, flex, gettext, xz, setupDebugInfoDirs }:
+{ lib, stdenv, fetchurl, m4, zlib, bzip2, bison, flex, gettext, xz, setupDebugInfoDirs, argp-standalone }:
 
 # TODO: Look at the hardcoded paths to kernel, modules etc.
 stdenv.mkDerivation rec {
   pname = "elfutils";
-  version = "0.176";
+  version = "0.180";
 
   src = fetchurl {
     url = "https://sourceware.org/elfutils/ftp/${version}/${pname}-${version}.tar.bz2";
-    sha256 = "08qhrl4g6qqr4ga46jhh78y56a47p3msa5b2x1qhzbxhf71lfmzb";
+    sha256 = "17an1f67bfzxin482nbcxdl5qvywm27i9kypjyx8ilarbkivc9xq";
   };
 
   patches = [ ./debug-info-from-env.patch ];
@@ -17,13 +17,19 @@ stdenv.mkDerivation rec {
   # We need bzip2 in NativeInputs because otherwise we can't unpack the src,
   # as the host-bzip2 will be in the path.
   nativeBuildInputs = [ m4 bison flex gettext bzip2 ];
-  buildInputs = [ zlib bzip2 xz ];
+  buildInputs = [ zlib bzip2 xz ]
+    ++ lib.optional stdenv.hostPlatform.isMusl argp-standalone;
 
   propagatedNativeBuildInputs = [ setupDebugInfoDirs ];
 
+  preConfigure = lib.optionalString stdenv.hostPlatform.isMusl ''
+    NIX_CFLAGS_COMPILE+=" -fgnu89-inline"
+  '';
+
   configureFlags =
     [ "--program-prefix=eu-" # prevent collisions with binutils
       "--enable-deterministic-archives"
+      "--disable-debuginfod"
     ];
 
   enableParallelBuilding = true;