# Maintainer: pkgname=py3-cairosvg _pyname=CairoSVG pkgver=2.7.0 pkgrel=1 pkgdesc="Cairo-based SVG renderer for python" url="https://cairosvg.org/" arch="noarch" license="LGPL-3.0-or-later" depends=" python3 py3-tinycss2 py3-cssselect2 py3-defusedxml py3-cairocffi py3-pillow " checkdepends=" py3-pillow py3-pytest py3-pytest-cov py3-pytest-flake8 py3-pytest-isort py3-pytest-runner " makedepends="python3-dev py3-setuptools cairo-dev py3-pytest-runner" _pypiprefix="${_pyname%${_pyname#?}}" subpackages="$pkgname-pyc" source="https://files.pythonhosted.org/packages/source/$_pypiprefix/$_pyname/$_pyname-$pkgver.tar.gz" builddir="$srcdir"/CairoSVG-$pkgver replaces="py-cairosvg" # Backwards compat provides="py-cairosvg=$pkgver-r$pkgrel" # Backwards compat # secfixes: # 2.7.0-r0: # - CVE-2023-27586 # 2.5.1-r0: # - CVE-2021-21236 prepare() { mkdir test_non_regression/cairosvg_reference/ cp -a $(ls -1 . | grep -v test_non_regression) test_non_regression/cairosvg_reference/ } build() { python3 setup.py build } check() { python3 setup.py pytest -v } package() { python3 setup.py install --skip-build --root="$pkgdir" } sha512sums=" 7775654f55ac436c91e781a91ca9ca89826068638fdbf65b9717899dfd5d974dacc7cf2e7ee24fad1be8ded899e1c1f441137f25c2a8185b67e7ecc84c2c9c50 CairoSVG-2.7.0.tar.gz "