www-client/google-chrome-beta: automated update (84.0.4147.30)
[gentoo.git] / dev-python / pyyaml / pyyaml-3.13.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5
6 PYTHON_COMPAT=( python2_7 python3_{6,7} pypy3 )
7
8 inherit distutils-r1
9
10 MY_P="PyYAML-${PV}"
11
12 DESCRIPTION="YAML parser and emitter for Python"
13 HOMEPAGE="https://pyyaml.org/wiki/PyYAML https://pypi.org/project/PyYAML/"
14 SRC_URI="https://pyyaml.org/download/${PN}/${MY_P}.tar.gz"
15
16 LICENSE="MIT"
17 SLOT="0"
18 KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 s390 sparc x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
19 IUSE="examples libyaml"
20
21 RDEPEND="libyaml? ( dev-libs/libyaml )"
22 DEPEND="${RDEPEND}
23         libyaml? ( $(python_gen_cond_dep 'dev-python/cython[${PYTHON_USEDEP}]' python2_7 'python3*') )"
24
25 S="${WORKDIR}/${MY_P}"
26
27 python_configure_all() {
28         mydistutilsargs=( $(use_with libyaml) )
29 }
30
31 python_test() {
32         esetup.py test
33 }
34
35 python_install_all() {
36         distutils-r1_python_install_all
37         if use examples; then
38                 dodoc -r examples
39                 docompress -x /usr/share/doc/${PF}
40         fi
41 }