nixpkgs/pkgs/tools/security/yara/default.nix

39 lines
1.0 KiB
Nix
Raw Normal View History

2017-02-02 03:58:13 +00:00
{ stdenv, fetchFromGitHub, autoconf, automake, libtool, pcre
2015-10-31 21:59:34 +00:00
, withCrypto ? true, openssl
, enableMagic ? true, file
, enableCuckoo ? true, jansson
}:
stdenv.mkDerivation rec {
version = "3.8.1";
2015-10-31 21:59:34 +00:00
name = "yara-${version}";
src = fetchFromGitHub {
2017-02-02 03:58:13 +00:00
owner = "VirusTotal";
2015-10-31 21:59:34 +00:00
repo = "yara";
rev = "v${version}";
sha256 = "1ys2y5f2cif3g42daq646jcrn2na19zkx7fds2gnavj5c1rk7463";
2015-10-31 21:59:34 +00:00
};
buildInputs = [ autoconf automake libtool pcre]
++ stdenv.lib.optionals withCrypto [ openssl ]
++ stdenv.lib.optionals enableMagic [ file ]
++ stdenv.lib.optionals enableCuckoo [ jansson ]
;
preConfigure = "./bootstrap.sh";
2018-07-25 22:44:21 +01:00
configureFlags = [
(stdenv.lib.withFeature withCrypto "crypto")
(stdenv.lib.enableFeature enableMagic "magic")
(stdenv.lib.enableFeature enableCuckoo "cuckoo")
];
2015-10-31 21:59:34 +00:00
meta = with stdenv.lib; {
description = "The pattern matching swiss knife for malware researchers";
2017-11-21 23:22:08 +00:00
homepage = http://Virustotal.github.io/yara/;
2015-10-31 21:59:34 +00:00
license = licenses.asl20;
platforms = stdenv.lib.platforms.all;
};
}