2017-05-14 22:25:14 +00:00
|
|
|
{ stdenv
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, cython
|
|
|
|
, python
|
|
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
2017-11-09 11:26:09 +00:00
|
|
|
pname = "cymem";
|
2018-10-20 10:04:59 +00:00
|
|
|
version = "2.0.2";
|
2017-11-09 11:26:09 +00:00
|
|
|
name = pname + "-" + version;
|
2017-05-14 22:25:14 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "explosion";
|
|
|
|
repo = "cymem";
|
2018-10-20 10:04:59 +00:00
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "109i67vwgql9za8mfvgbrd6rgraz4djkvpzb4gqvzl13214s6ava";
|
2017-05-14 22:25:14 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2017-11-09 11:26:09 +00:00
|
|
|
cython
|
2017-05-14 22:25:14 +00:00
|
|
|
];
|
2017-11-09 11:26:09 +00:00
|
|
|
|
2018-10-20 10:04:59 +00:00
|
|
|
prePatch = ''
|
|
|
|
substituteInPlace setup.py \
|
|
|
|
--replace "wheel>=0.32.0,<0.33.0" "wheel>=0.31.0"
|
|
|
|
'';
|
|
|
|
|
2017-05-14 22:25:14 +00:00
|
|
|
checkPhase = ''
|
|
|
|
cd cymem/tests
|
|
|
|
${python.interpreter} -m unittest discover -p "*test*"
|
|
|
|
'';
|
2017-11-09 11:26:09 +00:00
|
|
|
|
2017-05-14 22:25:14 +00:00
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Cython memory pool for RAII-style memory management";
|
|
|
|
homepage = https://github.com/explosion/cymem;
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ sdll ];
|
|
|
|
};
|
|
|
|
}
|