2022-08-21 13:32:41 +00:00
|
|
|
{ lib
|
|
|
|
, fetchFromGitHub
|
|
|
|
, buildPythonPackage
|
2023-08-04 22:07:22 +00:00
|
|
|
, packaging
|
|
|
|
, setuptools
|
|
|
|
, pkgconfig
|
|
|
|
, freetype
|
2022-08-21 13:32:41 +00:00
|
|
|
, pytest
|
|
|
|
, python
|
|
|
|
, pillow
|
|
|
|
, numpy
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "aggdraw";
|
2024-04-21 15:54:59 +00:00
|
|
|
version = "1.3.18";
|
2023-08-04 22:07:22 +00:00
|
|
|
format = "pyproject";
|
2022-08-21 13:32:41 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "pytroll";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2024-04-21 15:54:59 +00:00
|
|
|
hash = "sha256-dM6yLR6xsZerpqY+BMxIjrJ3fQty9CFUWhxl2zkTgRA=";
|
2022-08-21 13:32:41 +00:00
|
|
|
};
|
|
|
|
|
2023-08-04 22:07:22 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
packaging
|
|
|
|
setuptools
|
|
|
|
pkgconfig
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
freetype
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2022-08-21 13:32:41 +00:00
|
|
|
numpy
|
|
|
|
pillow
|
|
|
|
pytest
|
|
|
|
];
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
runHook preCheck
|
|
|
|
${python.interpreter} selftest.py
|
|
|
|
runHook postCheck
|
|
|
|
'';
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "aggdraw" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "High quality drawing interface for PIL";
|
|
|
|
homepage = "https://github.com/pytroll/aggdraw";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ onny ];
|
|
|
|
};
|
|
|
|
}
|