1{
2 lib,
3 buildPythonPackage,
4 defusedxml,
5 dissect-cstruct,
6 dissect-util,
7 fetchFromGitHub,
8 pycryptodome,
9 pytestCheckHook,
10 pythonOlder,
11 rich,
12 setuptools,
13 setuptools-scm,
14}:
15
16buildPythonPackage rec {
17 pname = "dissect-hypervisor";
18 version = "3.14";
19 pyproject = true;
20
21 disabled = pythonOlder "3.9";
22
23 src = fetchFromGitHub {
24 owner = "fox-it";
25 repo = "dissect.hypervisor";
26 rev = "refs/tags/${version}";
27 hash = "sha256-27GfO1HEy9EWdWuPkznOjju6Xy3W2kjKDP0gF3NqYs0=";
28 };
29
30 build-system = [
31 setuptools
32 setuptools-scm
33 ];
34
35 dependencies = [
36 defusedxml
37 dissect-cstruct
38 dissect-util
39 ];
40
41 passthru.optional-dependencies = {
42 full = [
43 pycryptodome
44 rich
45 ];
46 };
47
48 nativeCheckInputs = [ pytestCheckHook ];
49
50 pythonImportsCheck = [ "dissect.hypervisor" ];
51
52 meta = with lib; {
53 description = "Dissect module implementing parsers for various hypervisor disk, backup and configuration files";
54 homepage = "https://github.com/fox-it/dissect.hypervisor";
55 changelog = "https://github.com/fox-it/dissect.hypervisor/releases/tag/${version}";
56 license = licenses.agpl3Only;
57 maintainers = with maintainers; [ fab ];
58 };
59}