Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / pyfuse3 / default.nix
blob851b37bbfb9ca8c9e4cf15f22ba275ac8a2bb4ab
1 { lib
2 , buildPythonPackage
3 , pythonOlder
4 , fetchFromGitHub
5 , cython
6 , pkg-config
7 , setuptools
8 , fuse3
9 , trio
10 , python
11 , pytestCheckHook
12 , pytest-trio
13 , which
16 buildPythonPackage rec {
17   pname = "pyfuse3";
18   version = "3.3.0";
20   disabled = pythonOlder "3.8";
22   format = "pyproject";
24   src = fetchFromGitHub {
25     owner = "libfuse";
26     repo = "pyfuse3";
27     rev = "refs/tags/${version}";
28     hash = "sha256-GLGuTFdTA16XnXKSBD7ET963a8xH9EG/JfPNu6/3DOg=";
29   };
31   postPatch = ''
32     substituteInPlace setup.py \
33       --replace "'pkg-config'" "'$(command -v $PKG_CONFIG)'"
34   '';
36   nativeBuildInputs = [
37     cython
38     pkg-config
39     setuptools
40   ];
42   buildInputs = [ fuse3 ];
44   propagatedBuildInputs = [ trio ];
46   preBuild = ''
47     ${python.pythonOnBuildForHost.interpreter} setup.py build_cython
48   '';
50   nativeCheckInputs = [
51     pytestCheckHook
52     pytest-trio
53     which
54     fuse3
55   ];
57   # Checks if a /usr/bin directory exists, can't work on NixOS
58   disabledTests = [ "test_listdir" ];
60   pythonImportsCheck = [
61     "pyfuse3"
62     "pyfuse3_asyncio"
63   ];
65   meta = with lib; {
66     description = "Python 3 bindings for libfuse 3 with async I/O support";
67     homepage = "https://github.com/libfuse/pyfuse3";
68     license = licenses.lgpl2Plus;
69     maintainers = with maintainers; [ nyanloutre dotlambda ];
70     changelog = "https://github.com/libfuse/pyfuse3/blob/${version}/Changes.rst";
71   };