2021-04-13 19:44:15 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, pytestCheckHook
|
|
|
|
, yara
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "yara-python";
|
2021-10-28 06:52:43 +00:00
|
|
|
version = "4.1.3";
|
2021-04-13 19:44:15 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "VirusTotal";
|
|
|
|
repo = "yara-python";
|
|
|
|
rev = "v${version}";
|
2021-10-28 06:52:43 +00:00
|
|
|
sha256 = "sha256-lOP+OVnMgpP8S+Q3jGRNEAFXAohXgX5Nvl+l4EK5ebs=";
|
2021-04-13 19:44:15 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
yara
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
setupPyBuildFlags = [
|
|
|
|
"--dynamic-linking"
|
|
|
|
];
|
|
|
|
|
|
|
|
pytestFlagsArray = [ "tests.py" ];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "yara" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python interface for YARA";
|
|
|
|
homepage = "https://github.com/VirusTotal/yara-python";
|
|
|
|
license = with licenses; [ asl20 ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|