biome: 1.9.2 -> 1.9.3
[NixPkgs.git] / pkgs / tools / networking / jnettop / default.nix
blob0be765028635ae4f148220f74552f8adfa6a178b
1 { fetchurl, fetchpatch, lib, stdenv, autoconf, libpcap, ncurses, pkg-config, glib }:
3 stdenv.mkDerivation rec {
4   pname = "jnettop";
5   version = "0.13.0";
7   src = fetchurl {
8     url = "http://jnettop.kubs.info/dist/jnettop-${version}.tar.gz";
9     sha256 = "1855np7c4b0bqzhf1l1dyzxb90fpnvrirdisajhci5am6als31z9";
10   };
12   nativeBuildInputs = [ pkg-config autoconf ];
13   buildInputs = [ libpcap ncurses glib ];
15   patches = [
16     ./no-dns-resolution.patch
17     (fetchpatch {
18       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";
19       sha256 = "1b0alc12sj8pzcb66f8xslbqlbsvq28kz34v6jfhbb1q25hyr7jg";
20     })
22     # Fix pending upstream inclusion for ncurses-6.3:
23     #  https://sourceforge.net/p/jnettop/patches/5/
24     (fetchpatch {
25       name = "ncurses-6.3.patch";
26       url = "https://sourceforge.net/p/jnettop/patches/5/attachment/jnettop-0.13.0-ncurses-6.3.patch";
27       sha256 = "1a0g3bal6f2fh1sq9q5kfwljrnskfvrhdzhjadcds34gzsr26v7x";
28     })
29   ];
31   preConfigure = "autoconf ";
33   meta = {
34     description = "Network traffic visualizer";
36     longDescription = ''
37       Jnettop is a traffic visualiser, which captures traffic going
38       through the host it is running from and displays streams sorted
39       by bandwidth they use.
40     '';
42     homepage = "https://sourceforge.net/projects/jnettop/";
43     license = lib.licenses.gpl2Plus;
44     platforms = lib.platforms.unix;
45     mainProgram = "jnettop";
46   };