2021-02-05 17:12:51 +00:00
|
|
|
{ fetchurl, fetchpatch, lib, stdenv, autoconf, libpcap, ncurses, pkg-config, glib }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-08-05 21:33:18 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "jnettop";
|
|
|
|
version = "0.13.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2021-08-05 21:33:18 +00:00
|
|
|
url = "http://jnettop.kubs.info/dist/jnettop-${version}.tar.gz";
|
2020-04-24 23:36:52 +00:00
|
|
|
sha256 = "1855np7c4b0bqzhf1l1dyzxb90fpnvrirdisajhci5am6als31z9";
|
|
|
|
};
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
nativeBuildInputs = [ pkg-config autoconf ];
|
2020-04-24 23:36:52 +00:00
|
|
|
buildInputs = [ libpcap ncurses glib ];
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
./no-dns-resolution.patch
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://sources.debian.net/data/main/j/jnettop/0.13.0-1/debian/patches/0001-Use-64-bit-integers-for-byte-totals-support-bigger-u.patch";
|
|
|
|
sha256 = "1b0alc12sj8pzcb66f8xslbqlbsvq28kz34v6jfhbb1q25hyr7jg";
|
|
|
|
})
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
# Fix pending upstream inclusion for ncurses-6.3:
|
|
|
|
# https://sourceforge.net/p/jnettop/patches/5/
|
|
|
|
(fetchpatch {
|
|
|
|
name = "ncurses-6.3.patch";
|
|
|
|
url = "https://sourceforge.net/p/jnettop/patches/5/attachment/jnettop-0.13.0-ncurses-6.3.patch";
|
|
|
|
sha256 = "1a0g3bal6f2fh1sq9q5kfwljrnskfvrhdzhjadcds34gzsr26v7x";
|
|
|
|
})
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
preConfigure = "autoconf ";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Network traffic visualizer";
|
|
|
|
|
|
|
|
longDescription = ''
|
|
|
|
Jnettop is a traffic visualiser, which captures traffic going
|
|
|
|
through the host it is running from and displays streams sorted
|
|
|
|
by bandwidth they use.
|
|
|
|
'';
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
homepage = "https://sourceforge.net/projects/jnettop/";
|
2021-01-15 22:18:51 +00:00
|
|
|
license = lib.licenses.gpl2Plus;
|
|
|
|
platforms = lib.platforms.unix;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|