dev-qt/qttest: stable 5.14.2 for ppc, bug #719732
[gentoo.git] / dev-python / fonttools / fonttools-4.1.0.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=7
5
6 PYTHON_COMPAT=( python{3_6,3_7,3_8} )
7 PYTHON_REQ_USE="xml(+)"
8
9 inherit distutils-r1 virtualx
10
11 DESCRIPTION="Library for manipulating TrueType, OpenType, AFM and Type1 fonts"
12 HOMEPAGE="https://github.com/fonttools/fonttools/"
13 SRC_URI="https://github.com/fonttools/fonttools/archive/${PV}.tar.gz -> ${P}.tar.gz"
14
15 LICENSE="BSD"
16 SLOT="0"
17 KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ppc ppc64 sparc x86"
18 RESTRICT="!test? ( test )"
19 IUSE="test"
20
21 RDEPEND=""
22 DEPEND="${RDEPEND}
23         test? (
24                 >=dev-python/pytest-2.8[${PYTHON_USEDEP}]
25
26                 >=dev-python/fs-2.4.9[${PYTHON_USEDEP}]
27                 app-arch/brotli[python,${PYTHON_USEDEP}]
28                 app-arch/zopfli
29         )"
30
31 python_prepare_all() {
32         # When dev-python/pytest-shutil is installed, we get weird import errors.
33         # This is due to incomplete nesting in the Tests/ tree:
34         #
35         #   Tests/feaLib/__init__.py
36         #   Tests/ufoLib/__init__.py
37         #   Tests/svgLib/path/__init__.py
38         #   Tests/otlLib/__init__.py
39         #   Tests/varLib/__init__.py
40         #
41         # This tree requires an __init__.py in Tests/svgLib/ too, bug #701148.
42         touch Tests/svgLib/__init__.py || die
43
44         distutils-r1_python_prepare_all
45 }
46
47 python_test() {
48         # virtualx used when matplotlib is installed causing plot module tests to run
49         virtx pytest -vv Tests fontTools
50 }