2021-12-04 00:55:48 +01:00
|
|
|
{ lib, stdenv, fetchgit, pkg-config, libbpf, cmake, elfutils, zlib }:
|
2015-07-11 13:11:14 +02:00
|
|
|
|
2018-09-20 00:28:05 +02:00
|
|
|
stdenv.mkDerivation rec {
|
2019-06-28 01:54:27 +02:00
|
|
|
pname = "pahole";
|
2021-12-04 00:54:26 +01:00
|
|
|
version = "1.22";
|
2015-07-11 13:11:14 +02:00
|
|
|
src = fetchgit {
|
2020-04-01 03:11:51 +02:00
|
|
|
url = "https://git.kernel.org/pub/scm/devel/pahole/pahole.git";
|
2018-09-20 00:28:05 +02:00
|
|
|
rev = "v${version}";
|
2021-12-04 00:54:26 +01:00
|
|
|
sha256 = "sha256-U1/i9WNlLphPIcNysC476sqil/q9tMYmu+Y6psga8I0=";
|
2015-07-11 13:11:14 +02:00
|
|
|
};
|
|
|
|
|
2021-12-04 00:55:48 +01:00
|
|
|
nativeBuildInputs = [ cmake pkg-config ];
|
|
|
|
buildInputs = [ elfutils zlib libbpf ];
|
2018-09-20 00:28:05 +02:00
|
|
|
|
|
|
|
# Put libraries in "lib" subdirectory, not top level of $out
|
2021-12-04 00:55:48 +01:00
|
|
|
cmakeFlags = [ "-D__LIB=lib" "-DLIBBPF_EMBEDDED=OFF" ];
|
2015-07-11 13:11:14 +02:00
|
|
|
|
2021-01-23 13:26:19 +01:00
|
|
|
meta = with lib; {
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "https://git.kernel.org/cgit/devel/pahole/pahole.git/";
|
2015-07-11 13:11:14 +02:00
|
|
|
description = "Pahole and other DWARF utils";
|
2021-03-17 07:42:04 +01:00
|
|
|
license = licenses.gpl2Only;
|
2015-07-11 13:11:14 +02:00
|
|
|
|
|
|
|
platforms = platforms.linux;
|
2021-12-04 00:55:48 +01:00
|
|
|
maintainers = with maintainers; [ bosu martinetd ];
|
2015-07-11 13:11:14 +02:00
|
|
|
};
|
|
|
|
}
|