1{
2 lib,
3 fetchPypi,
4 stdenvNoCC,
5 buildPythonPackage,
6}:
7let
8 version = "17.2.11";
9 format = "wheel";
10 inherit (stdenvNoCC.hostPlatform) system;
11
12 # https://pypi.org/project/frida/#files
13 pypiMeta =
14 {
15 x86_64-linux = {
16 hash = "sha256-PSCT5Y3JaOo9uJgCzXQVmcDvNxUEEN5dvjRxiEMcJEQ=";
17 platform = "manylinux1_x86_64";
18 };
19 aarch64-linux = {
20 hash = "sha256-UH+f6Pj1BS2hcwz3WoSsBGRXOIM/y8D0ymk8s7BU2nw=";
21 platform = "manylinux2014_aarch64";
22 };
23 x86_64-darwin = {
24 hash = "sha256-zZms5eIguKTl5SYWtDNQwROPM2+5t8JVp/itIl9FkXs=";
25 platform = "macosx_10_13_x86_64";
26 };
27 aarch64-darwin = {
28 hash = "sha256-vzyHYlstwm1GT1jKc0g5Yr6JVte9WGn+hALYpkefKBY=";
29 platform = "macosx_11_0_arm64";
30 };
31 }
32 .${system} or (throw "Unsupported system: ${system}");
33in
34buildPythonPackage {
35 pname = "frida-python";
36 inherit version format;
37
38 src = fetchPypi {
39 pname = "frida";
40 inherit version format;
41 inherit (pypiMeta) hash platform;
42 abi = "abi3";
43 python = "cp37";
44 dist = "cp37";
45 };
46
47 pythonImportsCheck = [
48 "frida"
49 "frida._frida"
50 ];
51
52 meta = {
53 description = "Dynamic instrumentation toolkit for developers, reverse-engineers, and security researchers (Python bindings)";
54 homepage = "https://www.frida.re";
55 license = with lib.licenses; [
56 lgpl2Plus
57 wxWindowsException31
58 ];
59 maintainers = with lib.maintainers; [ s1341 ];
60 platforms = [
61 "x86_64-linux"
62 "aarch64-linux"
63 "x86_64-darwin"
64 "aarch64-darwin"
65 ];
66 };
67}