tcpflow: 1.4.5 -> 1.4.6 (#15151)

Switch to fetchFromGitHub as website does not have latest version.
Default to not building against cairo to avoid dependencies on lots
of graphic libraries for a predominently command-line application.
This commit is contained in:
obadz 2016-05-03 01:39:46 +01:00
parent 69ef7566a8
commit 8536d8b4ed

View File

@ -1,29 +1,61 @@
{stdenv, fetchurl, openssl, zlib, libpcap, boost, cairo}: { stdenv, lib, fetchFromGitHub, openssl, zlib, libpcap, boost, cairo, automake, autoconf, useCairo ? false }:
let
s = # Generated upstream information stdenv.mkDerivation rec {
rec { baseName = "tcpflow";
baseName="tcpflow"; version = "1.4.6";
version="1.4.5"; name = "${baseName}-${version}";
name="${baseName}-${version}";
hash="0whcyykq710s84jyiaqp6rsr19prd0pr1g1pg74mif0ig51yv7zk"; src = fetchFromGitHub {
url="http://www.digitalcorpora.org/downloads/tcpflow/tcpflow-1.4.5.tar.gz"; owner = "simsong";
sha256="0whcyykq710s84jyiaqp6rsr19prd0pr1g1pg74mif0ig51yv7zk"; repo = "tcpflow";
rev = "017687365b8233d16260f4afd7572c8ad8873cf6";
sha256 = "002cqmn786sjysf59xnbb7lgr23nqqslb2gvy29q2xpnq6my9w38";
}; };
buildInputs = [
openssl zlib libpcap boost cairo be13_api = fetchFromGitHub {
]; owner = "simsong";
in repo = "be13_api";
stdenv.mkDerivation { rev = "8f4f4b3fe0b4815babb3a6fb595eb9a6d07e8a2e";
inherit (s) name version; sha256 = "1dlys702x3m8cr9kf4b9j8n28yh6knhwgqkm6a5yhh1grd8r3ksm";
inherit buildInputs;
src = fetchurl {
inherit (s) url sha256;
}; };
meta = {
inherit (s) version; dfxml = fetchFromGitHub {
owner = "simsong";
repo = "dfxml";
rev = "13a8cc22189a8336d16777f2897ada6ae2ee59de";
sha256 = "0wzhbkp4c8sp6wrk4ilz3skxp14scdnm3mw2xmxxrsifymzs2f5n";
};
httpparser = fetchFromGitHub {
owner = "nodejs";
repo = "http-parser";
rev = "8d9e5db981b623fffc93657abacdc80270cbee58";
sha256 = "0x17wwhrc7b2ngiqy0clnzn1zz2gbcz5n9m29pcyrcplly782k52";
};
buildInputs = [ openssl zlib libpcap boost automake autoconf ] ++ lib.optional useCairo cairo;
postUnpack = ''
pushd tcpflow-*-src/src
cp -rv ${be13_api}/* be13_api/
cp -rv ${dfxml}/* dfxml/
cp -rv ${httpparser}/* http-parser/
chmod -R u+w dfxml
popd
'';
prePatch = ''
substituteInPlace ./bootstrap.sh \
--replace \ git 'echo git' \
--replace /bin/rm rm
'';
preConfigure = "bash ./bootstrap.sh";
meta = with stdenv.lib; {
description = ''TCP stream extractor''; description = ''TCP stream extractor'';
license = stdenv.lib.licenses.gpl3 ; license = licenses.gpl3 ;
maintainers = [stdenv.lib.maintainers.raskin]; maintainers = with maintainers; [ raskin obadz ];
platforms = stdenv.lib.platforms.linux; platforms = platforms.linux;
}; };
} }