mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-24 06:33:42 +00:00
46420bbaa3
treewide replacement of stdenv.mkDerivation rec { name = "*-${version}"; version = "*"; to pname
42 lines
921 B
Nix
42 lines
921 B
Nix
{stdenv, fetchFromGitHub, autoreconfHook, ncurses, libpcap }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
version = "3.5.1";
|
|
|
|
pname = "sipp";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "SIPp";
|
|
repo = "sipp";
|
|
rev = "v${version}";
|
|
sha256 = "179a1fvqyk3jpxbi28l1xfw22cw9vgvxrn19w5f38w74x0jwqg5k";
|
|
};
|
|
|
|
patchPhase = ''
|
|
sed -i "s@pcap/\(.*\).pcap@$out/share/pcap/\1.pcap@g" src/scenario.cpp
|
|
sed -i -e "s|AC_CHECK_LIB(curses|AC_CHECK_LIB(ncurses|" configure.ac
|
|
echo "#define SIPP_VERSION \"v${version}\"" > include/version.h
|
|
'';
|
|
|
|
configureFlags = [
|
|
"--with-pcap"
|
|
];
|
|
|
|
postInstall = ''
|
|
mkdir -pv $out/share/pcap
|
|
cp pcap/* $out/share/pcap
|
|
'';
|
|
|
|
buildInputs = [ncurses libpcap];
|
|
|
|
nativeBuildInputs = [ autoreconfHook ];
|
|
|
|
meta = with stdenv.lib; {
|
|
homepage = http://sipp.sf.net;
|
|
description = "The SIPp testing tool";
|
|
license = licenses.gpl3;
|
|
platforms = platforms.unix;
|
|
};
|
|
}
|
|
|