Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #117873 from fabaff/apkid
apkid: init at 2.1.1, python3Packages.yara-python: init at 4.0.5
- Loading branch information
Showing
5 changed files
with
98 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
{ lib | ||
, buildPythonPackage | ||
, fetchFromGitHub | ||
, pytestCheckHook | ||
, yara | ||
}: | ||
|
||
buildPythonPackage rec { | ||
pname = "yara-python"; | ||
version = "4.0.5"; | ||
|
||
src = fetchFromGitHub { | ||
owner = "VirusTotal"; | ||
repo = "yara-python"; | ||
rev = "v${version}"; | ||
sha256 = "1qd0aw5p48ay77hgj0hgzpvbmq1933mknk134aqdb32036rlc5sq"; | ||
}; | ||
|
||
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 ]; | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
{ lib | ||
, fetchFromGitHub | ||
, python3 | ||
}: | ||
|
||
python3.pkgs.buildPythonApplication rec { | ||
pname = "apkid"; | ||
version = "2.1.1"; | ||
|
||
src = fetchFromGitHub { | ||
owner = "rednaga"; | ||
repo = "APKiD"; | ||
rev = "v${version}"; | ||
sha256 = "1p6kdjjw2jhwr875445w43k46n6zwpz0l0phkl8d3y1v4gi5l6dx"; | ||
}; | ||
|
||
propagatedBuildInputs = with python3.pkgs; [ | ||
yara-python | ||
]; | ||
|
||
checkInputs = with python3.pkgs; [ | ||
pytestCheckHook | ||
]; | ||
|
||
preBuild = '' | ||
# Prepare the YARA rules | ||
${python3.interpreter} prep-release.py | ||
''; | ||
|
||
postPatch = '' | ||
# The next release will have support for later yara-python releases | ||
substituteInPlace setup.py \ | ||
--replace "yara-python==3.11.0" "yara-python" | ||
''; | ||
|
||
pythonImportsCheck = [ "apkid" ]; | ||
|
||
meta = with lib; { | ||
description = "Android Application Identifier"; | ||
homepage = "https://github.com/rednaga/APKiD"; | ||
license = with licenses; [ gpl3Only ]; | ||
maintainers = with maintainers; [ fab ]; | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters