dev-python/flask-browserid/flask-browserid-9999.ebuild
changeset 172 ff7ca16f5480
parent 51 a2ca63cc540e
equal deleted inserted replaced
161:df5c00aba7c2 172:ff7ca16f5480
     1 EAPI="3"
     1 # Copyright 1999-2015 Gentoo Foundation
     2 PYTHON_DEPEND="2:2.5"
     2 # Distributed under the terms of the GNU General Public License v2
     3 SUPPORT_PYTHON_ABIS="1"
     3 # $Id$
     4 RESTRICT_PYTHON_ABIS="2.4 3.*"
       
     5 
     4 
     6 inherit distutils git-2
     5 EAPI=5
       
     6 PYTHON_COMPAT=( python2_7 )
     7 
     7 
     8 EGIT_REPO_URI="git://github.com/garbados/flask-browserid.git"
     8 EGIT_REPO_URI="git://github.com/garbados/flask-browserid.git"
     9 
     9 
       
    10 [[ ${PV} == 9999 ]] && SCM=git-r3
       
    11 
       
    12 inherit distutils-r1 ${SCM}
       
    13 
    10 MY_PN="Flask-BrowserID"
    14 MY_PN="Flask-BrowserID"
    11 
       
    12 DESCRIPTION="Flask support for BrowserID authentication"
    15 DESCRIPTION="Flask support for BrowserID authentication"
    13 HOMEPAGE="http://pypi.python.org/pypi/Flask-BrowserID"
    16 HOMEPAGE="http://pypi.python.org/pypi/Flask-BrowserID"
       
    17 
       
    18 if [ ${PV} != 9999 ]; then
       
    19 	SRC_URI="mirror://pypi/${MY_PN:0:1}/${MY_PN}/${MY_PN}-${PV}.tar.gz"
       
    20 	S="${WORKDIR}/${MY_PN}-${PV}"
       
    21 fi
    14 
    22 
    15 LICENSE="MIT"
    23 LICENSE="MIT"
    16 SLOT="0"
    24 SLOT="0"
    17 KEYWORDS="~amd64 ~x86"
    25 KEYWORDS="~amd64 ~x86"
    18 IUSE="doc"
    26 IUSE="doc test"
    19 
    27 
    20 RDEPEND=">=dev-python/flask-0.9
    28 DEPEND="doc? ( dev-python/sphinx[${PYTHON_USEDEP}] ) "
    21 		>=dev-python/flask-login-0.1.3
    29 RDEPEND=">=dev-python/flask-0.9[${PYTHON_USEDEP}]
    22 		dev-python/requests
    30 		>=dev-python/flask-login-0.1.3[${PYTHON_USEDEP}]
    23 		doc? ( dev-python/sphinx ) "
    31 		dev-python/requests[${PYTHON_USEDEP}]
    24 DEPEND="${RDEPEND}
    32 		dev-python/setuptools[${PYTHON_USEDEP}]"
    25 	dev-python/setuptools"
       
    26 
    33 
    27 S="${WORKDIR}/${MY_P}"
    34 python_compile_all() {
    28 
       
    29 PYTHON_MODNAME="flaskext/browserid"
       
    30 
       
    31 src_compile() {
       
    32 	distutils_src_compile
       
    33 
       
    34 	if use doc; then
    35 	if use doc; then
    35 		einfo "Generation of documentation"
    36 		einfo "Generation of documentation"
    36 		cd docs
    37 		cd docs
    37 		PYTHONPATH=".." emake html || die "Generation of documentation failed"
    38 		emake html || die "Generation of documentation failed"
    38 	fi
    39 	fi
    39 }
    40 }
    40 
    41 
    41 src_install() {
    42 python_install_all() {
    42 	distutils_src_install
    43 	use doc && local HTML_DOCS=( doc/_build/html/. )
    43 
    44 
    44 	if use doc; then
    45 	distutils-r1_python_install_all
    45 		dohtml -r docs/_build/html/* || die "Installation of documentation failed"
       
    46 	fi
       
    47 }
    46 }
       
    47 
       
    48 python_test() {
       
    49 	esetup.py test
       
    50 }