anchor.diff:  
     propagatedNativeBuildInputs = [ setupDebugInfoDirs ];
   
  -  preConfigure = lib.optionalString stdenv.hostPlatform.isMusl ''
  -    NIX_CFLAGS_COMPILE+=" -Wno-null-dereference"
  -  '';
  +  NIX_CFLAGS_COMPILE = lib.optionals stdenv.hostPlatform.isMusl [
  +    "-Wno-null-dereference"
  +  ];
   
     configureFlags = [
       "--program-prefix=eu-" # prevent collisions with binutils
       "--enable-deterministic-archives"
  -  ] ++ lib.optionals (!enableDebuginfod) [
  -    "--disable-libdebuginfod"
  -    "--disable-debuginfod"
  +    (lib.enableFeature enableDebuginfod "libdebuginfod")
  +    (lib.enableFeature enableDebuginfod "debuginfod")
     ];
   
     enableParallelBuilding = true;
   
  -  doCheck = false; # fails 3 out of 174 tests
  -  doInstallCheck = false; # fails 70 out of 174 tests
  +  # Backtrace unwinding tests rely on glibc-internal symbol names.
  +  # Musl provides slightly different forms and fails.
  +  # Let's disable tests there until musl support is fully upstreamed.
  +  doCheck = !stdenv.hostPlatform.isMusl;
  +  doInstallCheck = !stdenv.hostPlatform.isMusl;
   
     meta = with lib; {
       homepage = "https://sourceware.org/elfutils/";
  
positive.code: # TODO: Look at the hardcoded paths to kernel, modules etc.
  stdenv.mkDerivation rec {
    pname = "elfutils";
    version = "0.182";
  
    src = fetchurl {
      url = "https://sourceware.org/elfutils/ftp/${version}/${pname}-${version}.tar.bz2";
      sha256 = "7MQGkU7fM18Lf8CE6+bEYMTW1Rdb/dZojBx42RRriFg=";
    };
  
    patches = [
  
negative.code:     # 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 ];
      maintainers = with maintainers; [ eelco r-burns ];
    };
  }
  