lol
at 18.03-beta 40 lines 917 B view raw
1{ stdenv, binutils, cmake, fetchFromGitHub }: 2 3stdenv.mkDerivation rec { 4 version = "2017-10-05"; 5 name = "bloaty-${version}"; 6 7 src = fetchFromGitHub { 8 owner = "google"; 9 repo = "bloaty"; 10 rev = "e47b21b01ceecf001e1965e9da249d48d86a1749"; 11 sha256 = "1il3z49hi0b07agjwr5fg1wzysfxsamfv1snvlp33vrlyl1m7cbm"; 12 fetchSubmodules = true; 13 }; 14 15 nativeBuildInputs = [ cmake ]; 16 17 enableParallelBuilding = true; 18 19 preConfigure = '' 20 substituteInPlace src/bloaty.cc \ 21 --replace "c++filt" \ 22 "${binutils.bintools}/bin/c++filt" 23 ''; 24 25 doCheck = true; 26 27 checkPhase = "ctest"; 28 29 installPhase = '' 30 install -Dm755 {.,$out/bin}/bloaty 31 ''; 32 33 meta = with stdenv.lib; { 34 description = "a size profiler for binaries"; 35 homepage = https://github.com/google/bloaty; 36 license = licenses.asl20; 37 platforms = platforms.unix; 38 maintainers = [ maintainers.dtzWill ]; 39 }; 40}