Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.09 1.6 kB view raw
1{ stdenv, fetchurl, fetchpatch, buildPythonPackage, pkgconfig, pytest, fuse, attr, which 2, contextlib2, osxfuse 3}: 4 5let 6 inherit (stdenv.lib) optionals optionalString; 7in 8 9buildPythonPackage rec { 10 pname = "llfuse"; 11 version = "1.3.6"; 12 13 src = fetchurl { 14 url = "mirror://pypi/l/llfuse/${pname}-${version}.tar.bz2"; 15 sha256 = "1j9fzxpgmb4rxxyl9jcf84zvznhgi3hnh4hg5vb0qaslxkvng8ii"; 16 }; 17 18 patches = [ 19 # https://github.com/python-llfuse/python-llfuse/pull/23 (2 commits) 20 (fetchpatch { 21 url = "https://github.com/python-llfuse/python-llfuse/commit/7579b0e626da1a7882b13caedcdbd4a834702e94.diff"; 22 sha256 = "0vpybj4k222h20lyn0q7hz86ziqlapqs5701cknw8d11jakbhhb0"; 23 }) 24 (fetchpatch { 25 url = "https://github.com/python-llfuse/python-llfuse/commit/438c00ab9e10d6c485bb054211c01b7f8524a736.diff"; 26 sha256 = "1zhb05b7k3c9mjqshy9in8yzpbihy7f33x1myq5kdjip1k50cwrn"; 27 }) 28 ]; 29 30 nativeBuildInputs = [ pkgconfig ]; 31 buildInputs = 32 optionals stdenv.isLinux [ fuse ] 33 ++ optionals stdenv.isDarwin [ osxfuse ]; 34 checkInputs = [ pytest which ] ++ 35 optionals stdenv.isLinux [ attr ]; 36 37 propagatedBuildInputs = [ contextlib2 ]; 38 39 checkPhase = '' 40 py.test -k "not test_listdir" ${optionalString stdenv.isDarwin ''-m "not uses_fuse"''} 41 ''; 42 43 meta = with stdenv.lib; { 44 description = "Python bindings for the low-level FUSE API"; 45 homepage = "https://github.com/python-llfuse/python-llfuse"; 46 license = licenses.lgpl2Plus; 47 platforms = platforms.unix; 48 maintainers = with maintainers; [ bjornfor ]; 49 }; 50}