2021-03-26 11:41:34 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, buildPythonPackage
|
|
|
|
, pythonOlder
|
|
|
|
, fetchFromGitHub
|
2021-03-23 14:15:56 +00:00
|
|
|
, contextlib2
|
2021-03-26 11:41:34 +00:00
|
|
|
, cython
|
|
|
|
, fuse
|
|
|
|
, pkg-config
|
|
|
|
, pytestCheckHook
|
|
|
|
, python
|
|
|
|
, which
|
2017-10-29 14:57:39 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2017-11-09 11:26:09 +00:00
|
|
|
pname = "llfuse";
|
2021-03-26 11:41:34 +00:00
|
|
|
version = "1.4.1";
|
2017-10-29 14:57:39 +00:00
|
|
|
|
2021-03-26 11:41:34 +00:00
|
|
|
disabled = pythonOlder "3.5";
|
2017-10-29 14:57:39 +00:00
|
|
|
|
2021-03-26 11:41:34 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "python-llfuse";
|
|
|
|
repo = "python-llfuse";
|
|
|
|
rev = "release-${version}";
|
|
|
|
sha256 = "1dcpdg6cpkmdbyg66fgrylj7dp9zqzg5bf23y6m6673ykgxlv480";
|
|
|
|
};
|
2020-12-07 20:07:49 +00:00
|
|
|
|
2021-03-26 11:41:34 +00:00
|
|
|
nativeBuildInputs = [ cython pkg-config ];
|
2021-01-24 00:29:22 +00:00
|
|
|
|
2021-03-23 14:15:56 +00:00
|
|
|
buildInputs = [ fuse ];
|
2021-01-24 00:29:22 +00:00
|
|
|
|
2017-10-29 14:57:39 +00:00
|
|
|
propagatedBuildInputs = [ contextlib2 ];
|
|
|
|
|
2021-03-26 11:41:34 +00:00
|
|
|
preBuild = ''
|
|
|
|
${python.interpreter} setup.py build_cython
|
2017-10-29 14:57:39 +00:00
|
|
|
'';
|
|
|
|
|
2021-03-26 18:18:29 +00:00
|
|
|
# On Darwin, the test requires macFUSE to be installed outside of Nix.
|
|
|
|
doCheck = !stdenv.isDarwin;
|
2021-03-26 11:41:34 +00:00
|
|
|
checkInputs = [ pytestCheckHook which ];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
"test_listdir" # accesses /usr/bin
|
|
|
|
];
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2017-10-29 14:57:39 +00:00
|
|
|
description = "Python bindings for the low-level FUSE API";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/python-llfuse/python-llfuse";
|
2017-10-29 14:57:39 +00:00
|
|
|
license = licenses.lgpl2Plus;
|
|
|
|
platforms = platforms.unix;
|
2021-03-26 11:41:34 +00:00
|
|
|
maintainers = with maintainers; [ bjornfor dotlambda ];
|
2017-10-29 14:57:39 +00:00
|
|
|
};
|
|
|
|
}
|