nixpkgs/pkgs/development/tools/misc/pahole/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

31 lines
928 B
Nix
Raw Normal View History

2022-01-11 16:26:52 +00:00
{ lib, stdenv, fetchgit, pkg-config, libbpf, cmake, elfutils, zlib, argp-standalone, musl-obstack }:
2015-07-11 11:11:14 +00:00
stdenv.mkDerivation rec {
2019-06-27 23:54:27 +00:00
pname = "pahole";
2021-12-20 13:00:12 +00:00
version = "1.23";
2015-07-11 11:11:14 +00:00
src = fetchgit {
url = "https://git.kernel.org/pub/scm/devel/pahole/pahole.git";
rev = "v${version}";
2021-12-20 13:00:12 +00:00
sha256 = "sha256-Dt3ZcUfjwdtTTv6qRFRgwK5GFWXdpN7fvb9KhpS1O94=";
2015-07-11 11:11:14 +00:00
};
nativeBuildInputs = [ cmake pkg-config ];
2022-01-11 16:26:52 +00:00
buildInputs = [ elfutils zlib libbpf ]
++ lib.optional stdenv.hostPlatform.isMusl [
argp-standalone
musl-obstack
];
# Put libraries in "lib" subdirectory, not top level of $out
cmakeFlags = [ "-D__LIB=lib" "-DLIBBPF_EMBEDDED=OFF" ];
2015-07-11 11:11:14 +00:00
meta = with lib; {
homepage = "https://git.kernel.org/pub/scm/devel/pahole/pahole.git/";
2015-07-11 11:11:14 +00:00
description = "Pahole and other DWARF utils";
license = licenses.gpl2Only;
2015-07-11 11:11:14 +00:00
platforms = platforms.linux;
maintainers = with maintainers; [ bosu martinetd ];
2015-07-11 11:11:14 +00:00
};
}