*/*: Clean PYTHON_COMPAT of obsolete impls
[gentoo.git] / dev-python / oauth2client / oauth2client-2.0.1.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI="5"
5
6 PYTHON_COMPAT=( python2_7 python3_6)
7
8 inherit distutils-r1
9
10 DESCRIPTION="Library for accessing resources protected by OAuth 2.0"
11 HOMEPAGE="https://github.com/google/oauth2client"
12 SRC_URI="https://github.com/google/oauth2client/archive/v${PV/_p/-post}.tar.gz -> ${P}.tar.gz"
13
14 LICENSE="Apache-2.0"
15 SLOT="0"
16 KEYWORDS="amd64 arm x86 ~amd64-linux ~x86-linux"
17 IUSE="test"
18
19 RDEPEND="
20         >=dev-python/httplib2-0.9.1[${PYTHON_USEDEP}]
21         >=dev-python/pyasn1-0.1.7[${PYTHON_USEDEP}]
22         >=dev-python/pyasn1-modules-0.0.5[${PYTHON_USEDEP}]
23         >=dev-python/rsa-3.1.4[${PYTHON_USEDEP}]
24         >=dev-python/six-1.6.1[${PYTHON_USEDEP}]
25         !<=dev-python/google-api-python-client-1.1[${PYTHON_USEDEP}]
26 "
27 DEPEND="${RDEPEND}
28         test? ( dev-python/nose[${PYTHON_USEDEP}] )
29 "
30
31 S="${WORKDIR}"/${P/_p/-post}
32
33 # Needs network
34 RESTRICT=test
35
36 python_prepare_all() {
37         sed \
38                 -e "s:find_packages():find_packages(exclude=['tests','tests.*']):" \
39                 -i setup.py || die
40         distutils-r1_python_prepare_all
41 }
42
43 python_test() {
44         nosetests || die
45 }