2009-10-12 13:08:52 +02:00
|
|
|
{stdenv, fetchurl, ncurses}:
|
|
|
|
|
2015-04-27 23:10:25 +02:00
|
|
|
let version = "1.14"; in
|
2009-10-12 13:08:52 +02:00
|
|
|
stdenv.mkDerivation rec {
|
2015-04-27 23:10:25 +02:00
|
|
|
name = "vnstat-${version}";
|
2012-09-01 21:53:58 +02:00
|
|
|
|
2009-10-12 13:08:52 +02:00
|
|
|
src = fetchurl {
|
2015-04-27 23:10:25 +02:00
|
|
|
sha256 = "11l39qqv5pgli9zzn0xilld67bi5qzxymsn97m4r022xv13jlipq";
|
2012-09-01 21:53:58 +02:00
|
|
|
url = "http://humdi.net/vnstat/${name}.tar.gz";
|
2009-10-12 13:08:52 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
installPhase = ''
|
2012-01-18 21:16:00 +01:00
|
|
|
mkdir -p $out/{bin,sbin} $out/share/man/{man1,man5}
|
2009-10-12 13:08:52 +02:00
|
|
|
cp src/vnstat $out/bin
|
|
|
|
cp src/vnstatd $out/sbin
|
|
|
|
cp man/vnstat.1 man/vnstatd.1 $out/share/man/man1
|
|
|
|
cp man/vnstat.conf.5 $out/share/man/man5
|
|
|
|
'';
|
|
|
|
|
|
|
|
buildInputs = [ncurses];
|
|
|
|
|
2015-04-27 23:10:25 +02:00
|
|
|
meta = with stdenv.lib; {
|
|
|
|
inherit version;
|
2009-10-12 13:08:52 +02:00
|
|
|
homepage = http://humdi.net/vnstat/;
|
2015-04-27 23:10:25 +02:00
|
|
|
license = licenses.gpl2Plus;
|
2009-10-12 13:08:52 +02:00
|
|
|
description = "Console-based network statistics utility for Linux";
|
2015-04-27 23:10:25 +02:00
|
|
|
maintainers = with maintainers; [ nckx ];
|
2009-10-12 13:08:52 +02:00
|
|
|
};
|
|
|
|
}
|