1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
5 PYTHON_COMPAT=( python2_7 python3_{6,7} )
9 DESCRIPTION="Library for accessing resources protected by OAuth 2.0"
10 HOMEPAGE="https://github.com/google/oauth2client"
11 SRC_URI="https://github.com/google/oauth2client/archive/v${PV/_p/-post}.tar.gz -> ${P}.tar.gz"
15 KEYWORDS="amd64 ~arm ~arm64 x86 ~amd64-linux ~x86-linux"
17 RESTRICT="!test? ( test )"
18 REQUIRED_USE="|| ( $(python_gen_useflags 'python*') )"
21 >=dev-python/httplib2-0.9.1[${PYTHON_USEDEP}]
22 >=dev-python/pyasn1-0.1.7[${PYTHON_USEDEP}]
23 >=dev-python/pyasn1-modules-0.0.5[${PYTHON_USEDEP}]
24 >=dev-python/rsa-3.1.4[${PYTHON_USEDEP}]
25 >=dev-python/six-1.6.1[${PYTHON_USEDEP}]
26 $(python_gen_cond_dep 'dev-python/keyring[${PYTHON_USEDEP}]' 'python*')
27 !<=dev-python/google-api-python-client-1.1[${PYTHON_USEDEP}]
30 dev-python/setuptools[${PYTHON_USEDEP}]
31 test? ( dev-python/nose[${PYTHON_USEDEP}] )
34 S="${WORKDIR}"/${P/_p/-post}
37 # keyring is not fuly supported by pypy yet, because dbus-python can't support pypy
38 # oauth2client -> keyring -> secretstorage -> dbus-python
39 # https://github.com/mitya57/secretstorage/issues/10
41 pypy|*pypy|*pypy3|pypy3) \
42 find "${BUILD_DIR}/.." -name '*keyring*py' -delete ;;
47 nosetests -e appengine -e django_util -e test_multiprocess_file_storage -e test_bad_positional || die
48 # appengine - requires appengine
49 # django_util - requires django
50 # test_multiprocess_file_storage - requires fasteners
51 # test_bad_positional - expects TypeError, gets ValueError