Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.09-beta 48 lines 990 B view raw
1{ lib 2, buildPythonPackage 3, fetchPypi 4, isPy3k 5, cssselect2 6, lxml 7, pillow 8, pytest 9, reportlab 10, tinycss2 11}: 12 13buildPythonPackage rec { 14 pname = "svglib"; 15 version = "1.0.1"; 16 17 src = fetchPypi { 18 inherit pname version; 19 sha256 = "ff01593e8c07ea462d3742e1f4141bfa261cbd4400ceb25dfb8fec3508ad0e50"; 20 }; 21 22 disabled = !isPy3k; 23 24 propagatedBuildInputs = [ 25 cssselect2 26 lxml 27 pillow 28 reportlab 29 tinycss2 30 ]; 31 32 checkInputs = [ 33 pytest 34 ]; 35 36 # Ignore tests that require network access (TestWikipediaFlags and TestW3CSVG), and tests that 37 # require files missing in the 1.0.0 PyPI release (TestOtherFiles). 38 checkPhase = '' 39 py.test svglib tests -k 'not TestWikipediaFlags and not TestW3CSVG and not TestOtherFiles' 40 ''; 41 42 meta = with lib; { 43 homepage = "https://github.com/deeplook/svglib"; 44 description = "A pure-Python library for reading and converting SVG"; 45 license = licenses.lgpl3; 46 maintainers = with maintainers; [ trepetti ]; 47 }; 48}