1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
5 PYTHON_COMPAT=( python2_7 python3_{5,6,7} )
9 DESCRIPTION="Amazon Web Services API"
10 HOMEPAGE="https://github.com/boto/boto https://pypi.org/project/boto/"
11 SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
15 KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
18 REQUIRED_USE="doc? ( || ( $(python_gen_useflags 'python2*') ) )"
21 dev-python/setuptools[${PYTHON_USEDEP}]
22 test? ( dev-python/nose[${PYTHON_USEDEP}] )
23 doc? ( dev-python/sphinx[${PYTHON_USEDEP}] )"
25 # requires Amazon Web Services keys to pass some tests
29 use doc && DISTUTILS_ALL_SUBPHASE_IMPLS=( 'python2*' )
33 "${PYTHON}" tests/test.py -v || die "Tests fail with ${EPYTHON}"
36 python_prepare_all() {
37 # Prevent un-needed d'loading
38 sed -e "s/, 'sphinx.ext.intersphinx'//" -i docs/source/conf.py || die
39 distutils-r1_python_prepare_all
42 python_compile_all() {
44 # Appease the doc build and supply a file for _static
45 # the usual emake -C docs doesn't work under this authorship
46 cd docs && mkdir source/_static || die
51 python_install_all() {
52 use doc && local HTML_DOCS=( docs/build/html/. )
53 distutils-r1_python_install_all