generated from nix-community/nur-packages-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathplasma-disassembler.nix
58 lines (50 loc) · 1.29 KB
/
plasma-disassembler.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
{ lib
, buildPythonApplication
, fetchFromGitHub
, msgpack
, nose
, pefile
, pyelftools
, capstone-system
, capstone
, python3
}:
buildPythonApplication rec {
pname = "plasma-disassembler";
version = "unstable-2019-03-04";
format = "setuptools";
src = fetchFromGitHub {
owner = "plasma-disassembler";
repo = "plasma";
rev = "ec7df9b2b9b356dd5d8caf01b7e68c0ab5a1ef42";
hash = "sha256-7XBvt+lYEEfXknFYrT+2KcrVSArlFNoq6cmnP1NWhsE=";
};
# fix: AttributeError: 'ParsedRequirement' object has no attribute 'req'
# https://github.com/plasma-disassembler/plasma/issues/106
postPatch = ''
sed -i "s/if item.req:/if getattr(item, 'req', None):/" setup.py
'';
propagatedBuildInputs = [
msgpack
nose
pefile
pyelftools
capstone
];
buildInputs = [
capstone-system
];
# fix: Testing via this command is deprecated
checkPhase = ''
runHook preCheck
${python3.interpreter} -m unittest
runHook postCheck
'';
pythonImportsCheck = [ "plasma" ];
meta = with lib; {
description = "Plasma is an interactive disassembler for x86/ARM/MIPS. It can generates indented pseudo-code with colored syntax";
homepage = "https://github.com/plasma-disassembler/plasma";
license = licenses.gpl3Only;
maintainers = with maintainers; [ ];
};
}