git.iko.soy/typeable/nixpkgs
on master help sign in
bloaty: 2016-12-28 -> 2017-10-05

* use fetchFromGitHub now that it supports submodules * change version style to dashes per guidelines (https://nixos.org/nixpkgs/manual/#sec-package-naming) * cmake * prefer substituteInPlace * run tests

commit7637cb884c3f38ca61c38741a52d002321ba91f8 authorWill Dietz <w@wdtz.org> dateWed 19 Jul 2017, 06:45 (9 years ago) parent6d7d7c5
1 file changed+17−8
pkgs/development/tools/bloaty/default.nix+17−8
pkgs/development/tools/bloaty/default.nix+17−8
@@ -1,22 +1,31 @@
1−{ stdenv, binutils, fetchgit }:
1+{ stdenv, binutils, cmake, fetchFromGitHub }:
22
33stdenv.mkDerivation rec {
4− version = "2016.12.28";
4+ version = "2017-10-05";
55 name = "bloaty-${version}";
66
7− src = fetchgit {
8− url = "https://github.com/google/bloaty.git";
9− rev = "2234386bcee7297dfa1b6d8a5d20f95ea4ed9bb0";
10− sha256 = "0cfsjgbp9r16d6qi8v4k609bbhjff4vhdiapfkhr34z1cik1md4l";
7+ src = fetchFromGitHub {
8+ owner = "google";
9+ repo = "bloaty";
10+ rev = "e47b21b01ceecf001e1965e9da249d48d86a1749";
11+ sha256 = "1il3z49hi0b07agjwr5fg1wzysfxsamfv1snvlp33vrlyl1m7cbm";
1112 fetchSubmodules = true;
1213 };
1314
15+ nativeBuildInputs = [ cmake ];
16+
1417 enableParallelBuilding = true;
1518
16− configurePhase = ''
17− sed -i 's,c++filt,${binutils}/bin/c++filt,' src/bloaty.cc
19+ preConfigure = ''
20+ substituteInPlace src/bloaty.cc \
21+ --replace "c++filt" \
22+ "${stdenv.lib.getBin binutils}/bin/c++filt"
1823 '';
1924
25+ doCheck = true;
26+
27+ checkPhase = "ctest";
28+
2029 installPhase = ''
2130 install -Dm755 {.,$out/bin}/bloaty
2231 '';