2020-08-12 21:50:23 +01:00
|
|
|
{ stdenv, fetchgit, autoconf, popt, zlib, rpcsvc-proto, libtirpc }:
|
2011-08-25 02:00:13 +01:00
|
|
|
|
2019-08-13 22:52:01 +01:00
|
|
|
stdenv.mkDerivation {
|
2015-09-26 14:01:39 +01:00
|
|
|
name = "dbench-2013-01-01";
|
2011-08-25 02:00:13 +01:00
|
|
|
|
|
|
|
src = fetchgit {
|
2020-04-01 02:11:51 +01:00
|
|
|
url = "git://git.samba.org/sahlberg/dbench.git";
|
2015-09-26 14:01:39 +01:00
|
|
|
rev = "65b19870ed8d25bff14cafa1c30beb33f1fb6597";
|
2016-06-02 12:26:44 +01:00
|
|
|
sha256 = "16lcbwmmx8z5i73k3dnf54yffrpx7ql3y9k3cpkss9dcyxb1p83i";
|
2011-08-25 02:00:13 +01:00
|
|
|
};
|
|
|
|
|
2020-08-12 21:50:23 +01:00
|
|
|
nativeBuildInputs = [ autoconf rpcsvc-proto ];
|
|
|
|
buildInputs = [ popt zlib libtirpc ];
|
|
|
|
NIX_CFLAGS_COMPILE = [ "-I${libtirpc.dev}/include/tirpc" ];
|
|
|
|
NIX_LDFLAGS = [ "-ltirpc" ];
|
2015-09-26 14:03:49 +01:00
|
|
|
|
2017-11-08 12:28:32 +00:00
|
|
|
patches = [
|
|
|
|
# patch has been also sent upstream and might be included in future versions
|
|
|
|
./fix-missing-stdint.patch
|
|
|
|
];
|
|
|
|
|
2015-09-26 14:03:49 +01:00
|
|
|
preConfigure = ''
|
|
|
|
./autogen.sh
|
2017-10-13 15:28:32 +01:00
|
|
|
configureFlagsArray+=("--datadir=$out/share/dbench")
|
2015-09-26 14:03:49 +01:00
|
|
|
'';
|
|
|
|
|
2011-08-25 02:00:13 +01:00
|
|
|
postInstall = ''
|
2017-10-13 15:28:32 +01:00
|
|
|
cp -R loadfiles/* $out/share/dbench/doc/dbench/loadfiles
|
|
|
|
|
|
|
|
# dbench looks here for the file
|
|
|
|
ln -s doc/dbench/loadfiles/client.txt $out/share/dbench/client.txt
|
|
|
|
|
|
|
|
# backwards compatible to older nixpkgs packaging introduced by
|
|
|
|
# 3f27be8e5d5861cd4b9487d6c5212d88bf24316d
|
|
|
|
ln -s dbench/doc/dbench/loadfiles $out/share/loadfiles
|
2011-08-25 02:00:13 +01:00
|
|
|
'';
|
|
|
|
|
2015-09-26 14:03:49 +01:00
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Filesystem benchmark tool based on load patterns";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://dbench.samba.org/";
|
2015-09-26 14:03:49 +01:00
|
|
|
license = licenses.gpl3;
|
2017-09-11 14:31:43 +01:00
|
|
|
platforms = platforms.linux;
|
2015-09-26 14:03:49 +01:00
|
|
|
maintainers = [ maintainers.bjornfor ];
|
|
|
|
};
|
2011-08-25 02:00:13 +01:00
|
|
|
}
|