1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, pytestCheckHook
5}:
6
7buildPythonPackage rec {
8 pname = "cstruct";
9 version = "5.2";
10 format = "setuptools";
11
12 src = fetchFromGitHub {
13 owner = "andreax79";
14 repo = "python-cstruct";
15 rev = "v${version}";
16 hash = "sha256-Dwogf0mmxFyBV7tPsuKV6gMZLPSCm7YhzqgJNHpaPFA=";
17 };
18
19 pythonImportsCheck = [
20 "cstruct"
21 ];
22
23 nativeCheckInputs = [
24 pytestCheckHook
25 ];
26
27 meta = with lib; {
28 description = "C-style structs for Python";
29 homepage = "https://github.com/andreax79/python-cstruct";
30 changelog = "https://github.com/andreax79/python-cstruct/blob/v${version}/changelog.txt";
31 license = licenses.mit;
32 maintainers = with maintainers; [ tnias ];
33 };
34}