at master 1.1 kB view raw
1{ 2 lib, 3 stdenv, 4 buildPythonPackage, 5 cython, 6 fetchFromGitHub, 7 libstatgrab, 8 pkg-config, 9 pythonOlder, 10 setuptools, 11 unittestCheckHook, 12}: 13 14buildPythonPackage rec { 15 pname = "pystatgrab"; 16 version = "0.7.2"; 17 pyproject = true; 18 19 disabled = pythonOlder "3.7"; 20 21 src = fetchFromGitHub { 22 owner = "libstatgrab"; 23 repo = "pystatgrab"; 24 rev = "PYSTATGRAB_${lib.replaceStrings [ "." ] [ "_" ] version}"; 25 hash = "sha256-0FDhkIK8jy3/SFmCzrl9l4RTeIKDjO0o5UoODx6Wnfs="; 26 }; 27 28 build-system = [ setuptools ]; 29 30 nativeBuildInputs = [ 31 cython 32 pkg-config 33 ]; 34 35 buildInputs = [ libstatgrab ]; 36 37 nativeCheckInputs = [ unittestCheckHook ]; 38 39 pythonImportsCheck = [ "statgrab" ]; 40 41 meta = with lib; { 42 description = "Python bindings for libstatgrab"; 43 homepage = "https://github.com/libstatgrab/pystatgrab"; 44 changelog = "https://github.com/libstatgrab/pystatgrab/blob/PYSTATGRAB_${ 45 lib.replaceStrings [ "." ] [ "_" ] version 46 }/NEWS"; 47 license = licenses.lgpl21Only; 48 maintainers = with maintainers; [ fab ]; 49 }; 50}