at 23.05-pre 1.1 kB view raw
1{ lib 2, buildPythonPackage 3, pythonOlder 4, fetchPypi 5, cssselect2 6, lxml 7, pillow 8, pytestCheckHook 9, reportlab 10, tinycss2 11}: 12 13buildPythonPackage rec { 14 pname = "svglib"; 15 version = "1.4.1"; 16 17 disabled = pythonOlder "3.7"; 18 19 format = "setuptools"; 20 21 src = fetchPypi { 22 inherit pname version; 23 sha256 = "sha256-SMJHBsI7tCYhc7b6Seq7EK+hW4QS8UKDEgVJUXzPoxQ="; 24 }; 25 26 propagatedBuildInputs = [ 27 cssselect2 28 lxml 29 pillow 30 reportlab 31 tinycss2 32 ]; 33 34 checkInputs = [ 35 pytestCheckHook 36 ]; 37 38 # Ignore tests that require network access (TestWikipediaFlags and TestW3CSVG), and tests that 39 # require files missing in the 1.0.0 PyPI release (TestOtherFiles). 40 pytestFlagsArray = [ 41 "-k 'not TestWikipediaFlags and not TestW3CSVG and not TestOtherFiles'" 42 ]; 43 44 pythonImportsCheck = [ "svglib.svglib" ]; 45 46 meta = with lib; { 47 homepage = "https://github.com/deeplook/svglib"; 48 description = "A pure-Python library for reading and converting SVG"; 49 license = licenses.lgpl3; 50 maintainers = with maintainers; [ trepetti ]; 51 }; 52}