Unverified Commit 34ae57af authored by Franz Pletz's avatar Franz Pletz
Browse files

iperf2: modernize & refactor

parent 389f490d
Loading
Loading
Loading
Loading
+4 −7
Original line number Diff line number Diff line
@@ -4,20 +4,17 @@
  fetchurl,
}:

stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
  pname = "iperf";
  version = "2.2.1";

  src = fetchurl {
    url = "mirror://sourceforge/iperf2/files/${pname}-${version}.tar.gz";
    sha256 = "1yyqzgz526xn6v2hrdiizviddx3xphjg93ihh7mdncw0wakv0jkm";
    url = "mirror://sourceforge/iperf2/files/iperf-${finalAttrs.version}.tar.gz";
    hash = "sha256-dUqwp+KAM9vqgTCO9CS8ffTW4v4xtgzFNrYbUf772Ps=";
  };

  hardeningDisable = [ "format" ];
  configureFlags = [ "--enable-fastsampling" ];

  makeFlags = [ "AR:=$(AR)" ];

  postInstall = ''
    mv $out/bin/iperf $out/bin/iperf2
    ln -s $out/bin/iperf2 $out/bin/iperf
@@ -32,4 +29,4 @@ stdenv.mkDerivation rec {
    # prioritize iperf3
    priority = 10;
  };
}
})