at 23.05-pre 1.3 kB view raw
1{ lib 2, stdenv 3, buildPythonPackage 4, pythonOlder 5, fetchFromGitHub 6, contextlib2 7, cython 8, fuse 9, pkg-config 10, pytestCheckHook 11, python 12, which 13}: 14 15buildPythonPackage rec { 16 pname = "llfuse"; 17 version = "1.4.2"; 18 19 disabled = pythonOlder "3.5"; 20 21 src = fetchFromGitHub { 22 owner = "python-llfuse"; 23 repo = "python-llfuse"; 24 rev = "release-${version}"; 25 hash = "sha256-TnZnv439fLvg0WM96yx0dPSSz8Mrae6GDC9LiLFrgQ8="; 26 }; 27 28 nativeBuildInputs = [ cython pkg-config ]; 29 30 buildInputs = [ fuse ]; 31 32 propagatedBuildInputs = [ contextlib2 ]; 33 34 preConfigure = '' 35 substituteInPlace setup.py \ 36 --replace "'pkg-config'" "'${stdenv.cc.targetPrefix}pkg-config'" 37 ''; 38 39 preBuild = '' 40 ${python.pythonForBuild.interpreter} setup.py build_cython 41 ''; 42 43 # On Darwin, the test requires macFUSE to be installed outside of Nix. 44 doCheck = !stdenv.isDarwin; 45 checkInputs = [ pytestCheckHook which ]; 46 47 disabledTests = [ 48 "test_listdir" # accesses /usr/bin 49 ]; 50 51 meta = with lib; { 52 description = "Python bindings for the low-level FUSE API"; 53 homepage = "https://github.com/python-llfuse/python-llfuse"; 54 license = licenses.lgpl2Plus; 55 platforms = platforms.unix; 56 maintainers = with maintainers; [ bjornfor dotlambda ]; 57 }; 58}