Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at netboot-syslinux-multiplatform 46 lines 1.1 kB view raw
1{ lib 2, stdenv 3, fetchzip 4, pkg-config 5, libbpf 6, cmake 7, elfutils 8, zlib 9, argp-standalone 10, musl-obstack 11, nixosTests 12}: 13 14stdenv.mkDerivation rec { 15 pname = "pahole"; 16 version = "1.25"; 17 src = fetchzip { 18 url = "https://git.kernel.org/pub/scm/devel/pahole/pahole.git/snapshot/pahole-${version}.tar.gz"; 19 hash = "sha256-s0YVT2UnMSO8jS/4XCt06wNPV4czHH6bmZRy/snO3jg="; 20 }; 21 22 nativeBuildInputs = [ cmake pkg-config ]; 23 buildInputs = [ elfutils zlib libbpf ] 24 ++ lib.optionals stdenv.hostPlatform.isMusl [ 25 argp-standalone 26 musl-obstack 27 ]; 28 29 patches = [ ./threading-reproducibility.patch ]; 30 31 # Put libraries in "lib" subdirectory, not top level of $out 32 cmakeFlags = [ "-D__LIB=lib" "-DLIBBPF_EMBEDDED=OFF" ]; 33 34 passthru.tests = { 35 inherit (nixosTests) bpf; 36 }; 37 38 meta = with lib; { 39 homepage = "https://git.kernel.org/pub/scm/devel/pahole/pahole.git/"; 40 description = "Shows, manipulates, and pretty-prints debugging information in DWARF, CTF, and BTF formats"; 41 license = licenses.gpl2Only; 42 43 platforms = platforms.linux; 44 maintainers = with maintainers; [ bosu martinetd ]; 45 }; 46}