1{ lib, stdenv, fetchFromGitHub, perl }:
2
3stdenv.mkDerivation rec {
4 pname = "FlameGraph";
5 version = "2019-02-16";
6
7 src = fetchFromGitHub {
8 owner = "brendangregg";
9 repo = pname;
10 rev = "1b1c6deede9c33c5134c920bdb7a44cc5528e9a7";
11 sha256 = "1flvkmv2gbb003d51myl7r0wyhyw1bk9p7v19xagb8xjj4ci947b";
12 };
13
14 buildInputs = [ perl ];
15
16 installPhase = ''
17 runHook preInstall
18
19 mkdir -p $out/bin
20 for x in $src/*.pl $src/*.awk $src/dev/*.pl $src/dev/*.d; do
21 cp $x $out/bin
22 done
23
24 runHook postInstall
25 '';
26
27 meta = with lib; {
28 license = with licenses; [ asl20 cddl gpl2Plus ];
29 homepage = "http://www.brendangregg.com/flamegraphs.html";
30 description = "Visualization for profiled code";
31 platforms = platforms.unix;
32 };
33}