1{ lib 2, fetchFromGitHub 3, buildPythonPackage 4, pytest_5 5, numpy 6, scipy 7, matplotlib 8, docutils 9, pyopencl 10, opencl-headers 11}: 12 13buildPythonPackage rec { 14 pname = "sasmodels"; 15 version = "1.0.5"; 16 17 src = fetchFromGitHub { 18 owner = "SasView"; 19 repo = "sasmodels"; 20 rev = "v${version}"; 21 sha256 = "19h30kcgpvg1qirzjm0vhgvp1yn60ivlglc8a8n2b4d9fp0acfyd"; 22 }; 23 24 buildInputs = [ opencl-headers ]; 25 # Note: the 1.0.5 release should be compatible with pytest6, so this can 26 # be set back to 'pytest' at that point 27 checkInputs = [ pytest_5 ]; 28 propagatedBuildInputs = [ docutils matplotlib numpy scipy pyopencl ]; 29 30 checkPhase = '' 31 HOME=$(mktemp -d) py.test -c ./pytest.ini 32 ''; 33 34 meta = { 35 description = "Library of small angle scattering models"; 36 homepage = "http://sasview.org"; 37 license = lib.licenses.bsd3; 38 maintainers = with lib.maintainers; [ rprospero ]; 39 }; 40}