From 83a096d042e0aa9f59ad339876157bab7f77074f Mon Sep 17 00:00:00 2001 From: Peter Hoeg Date: Wed, 8 Aug 2018 19:10:20 +0800 Subject: [PATCH] fio: 3.7 -> 3.8 --- pkgs/tools/system/fio/default.nix | 27 ++++++++++++++++----------- 1 file changed, 16 insertions(+), 11 deletions(-) diff --git a/pkgs/tools/system/fio/default.nix b/pkgs/tools/system/fio/default.nix index 2a5eea0b2516..261f4cee2b83 100644 --- a/pkgs/tools/system/fio/default.nix +++ b/pkgs/tools/system/fio/default.nix @@ -1,23 +1,23 @@ -{ stdenv, fetchFromGitHub, libaio, python, zlib }: - -let - version = "3.7"; - sha256 = "1m2slyxhzyznq283m6ljjgjg38i0hxg537bwhfs12qskv00c4vsk"; -in +{ stdenv, fetchFromGitHub, makeWrapper +, libaio, python, zlib +, withGnuplot ? false, gnuplot ? null }: stdenv.mkDerivation rec { name = "fio-${version}"; + version = "3.8"; src = fetchFromGitHub { - owner = "axboe"; - repo = "fio"; - rev = "fio-${version}"; - inherit sha256; + owner = "axboe"; + repo = "fio"; + rev = "fio-${version}"; + sha256 = "1krifr4ms7x229a3p088zl5rpdrfwz6bw4c2lrz3hksignjxaw91"; }; buildInputs = [ python zlib ] ++ stdenv.lib.optional (!stdenv.isDarwin) libaio; + nativeBuildInputs = [ makeWrapper ]; + enableParallelBuilding = true; postPatch = '' @@ -27,9 +27,14 @@ stdenv.mkDerivation rec { substituteInPlace tools/plot/fio2gnuplot --replace /usr/share/fio $out/share/fio ''; + postInstall = stdenv.lib.optionalString withGnuplot '' + wrapProgram $out/bin/fio2gnuplot \ + --prefix PATH : ${stdenv.lib.makeBinPath [ gnuplot ]} + ''; + meta = with stdenv.lib; { - homepage = "http://git.kernel.dk/?p=fio.git;a=summary;"; description = "Flexible IO Tester - an IO benchmark tool"; + homepage = "http://git.kernel.dk/?p=fio.git;a=summary;"; license = licenses.gpl2; platforms = platforms.unix; };