2022-03-08 18:18:51 +00:00
|
|
|
{ lib, stdenv, fetchurl, autoreconfHook, fetchFromGitHub, unstableGitUpdater }:
|
2016-09-20 11:57:57 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2022-02-06 20:45:05 +00:00
|
|
|
pname = "patchelf";
|
2022-10-26 11:50:01 +00:00
|
|
|
version = "unstable-2022-10-26";
|
2016-09-20 11:57:57 +00:00
|
|
|
|
2020-06-03 14:06:52 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "NixOS";
|
|
|
|
repo = "patchelf";
|
2022-10-26 11:50:01 +00:00
|
|
|
rev = "af77f12554be9cc4b9e8b639df26f2659dd30500";
|
|
|
|
sha256 = "sha256-ajMOC1wyTVUOvP0rOt/uO6+1+S4bIAc1jWQ8Uwbzrn8=";
|
2016-09-20 11:57:57 +00:00
|
|
|
};
|
|
|
|
|
2018-01-22 21:03:37 +00:00
|
|
|
# Drop test that fails on musl (?)
|
2021-01-23 12:26:19 +00:00
|
|
|
postPatch = lib.optionalString stdenv.hostPlatform.isMusl ''
|
2018-01-22 21:03:37 +00:00
|
|
|
substituteInPlace tests/Makefile.am \
|
|
|
|
--replace "set-rpath-library.sh" ""
|
|
|
|
'';
|
|
|
|
|
2016-09-20 11:57:57 +00:00
|
|
|
setupHook = [ ./setup-hook.sh ];
|
|
|
|
|
2017-09-05 21:26:13 +00:00
|
|
|
nativeBuildInputs = [ autoreconfHook ];
|
|
|
|
buildInputs = [ ];
|
2016-09-20 11:57:57 +00:00
|
|
|
|
2018-08-22 00:06:45 +00:00
|
|
|
doCheck = !stdenv.isDarwin;
|
2016-09-20 11:57:57 +00:00
|
|
|
|
2022-03-08 18:18:51 +00:00
|
|
|
passthru = {
|
|
|
|
updateScript = unstableGitUpdater {
|
|
|
|
url = "https://github.com/NixOS/patchelf.git";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2021-01-23 12:26:19 +00:00
|
|
|
meta = with lib; {
|
2021-09-21 11:04:09 +00:00
|
|
|
homepage = "https://github.com/NixOS/patchelf";
|
2019-09-22 07:38:09 +00:00
|
|
|
license = licenses.gpl3;
|
2016-09-20 11:57:57 +00:00
|
|
|
description = "A small utility to modify the dynamic linker and RPATH of ELF executables";
|
2019-09-22 07:38:09 +00:00
|
|
|
maintainers = [ maintainers.eelco ];
|
|
|
|
platforms = platforms.all;
|
2016-09-20 11:57:57 +00:00
|
|
|
};
|
|
|
|
}
|