2024-05-07 23:08:19 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
dissect-cstruct,
|
|
|
|
dissect-util,
|
|
|
|
fetchFromGitHub,
|
|
|
|
setuptools,
|
|
|
|
setuptools-scm,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
2022-10-07 20:21:26 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "dissect-shellitem";
|
2024-09-10 16:38:35 +00:00
|
|
|
version = "3.10";
|
2024-05-07 23:07:39 +00:00
|
|
|
pyproject = true;
|
2022-10-07 20:21:26 +00:00
|
|
|
|
2024-07-04 19:53:40 +00:00
|
|
|
disabled = pythonOlder "3.9";
|
2022-10-07 20:21:26 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "fox-it";
|
|
|
|
repo = "dissect.shellitem";
|
2023-02-11 09:44:47 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2024-09-10 16:38:35 +00:00
|
|
|
hash = "sha256-BS+c9QbMMsaoZHyuv6jMxbQFQNJeLt3da8Fq/wwXesQ=";
|
2022-10-07 20:21:26 +00:00
|
|
|
};
|
|
|
|
|
2024-05-07 23:07:39 +00:00
|
|
|
build-system = [
|
2022-10-07 20:21:26 +00:00
|
|
|
setuptools
|
|
|
|
setuptools-scm
|
|
|
|
];
|
|
|
|
|
2024-05-07 23:07:39 +00:00
|
|
|
dependencies = [
|
2022-10-07 20:21:26 +00:00
|
|
|
dissect-cstruct
|
|
|
|
dissect-util
|
|
|
|
];
|
|
|
|
|
2024-05-07 23:08:19 +00:00
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
2022-10-07 20:21:26 +00:00
|
|
|
|
2024-05-07 23:08:19 +00:00
|
|
|
pythonImportsCheck = [ "dissect.shellitem" ];
|
2022-10-07 20:21:26 +00:00
|
|
|
|
2024-11-18 20:22:04 +00:00
|
|
|
disabledTests = [
|
|
|
|
# Windows-specific tests
|
|
|
|
"test_xp_remote_lnk_file"
|
|
|
|
"test_xp_remote_lnk_dir"
|
|
|
|
"test_win7_local_lnk_dir"
|
|
|
|
];
|
|
|
|
|
2022-10-07 20:21:26 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Dissect module implementing a parser for the Shellitem structures";
|
|
|
|
homepage = "https://github.com/fox-it/dissect.shellitem";
|
2023-02-11 09:46:02 +00:00
|
|
|
changelog = "https://github.com/fox-it/dissect.shellitem/releases/tag/${version}";
|
2022-10-07 20:21:26 +00:00
|
|
|
license = licenses.agpl3Only;
|
|
|
|
maintainers = with maintainers; [ fab ];
|
2024-11-18 20:22:04 +00:00
|
|
|
mainProgram = "parse-lnk";
|
2022-10-07 20:21:26 +00:00
|
|
|
};
|
|
|
|
}
|