-
Notifications
You must be signed in to change notification settings - Fork 2
/
pyontutils-9999.ebuild
97 lines (85 loc) · 2.41 KB
/
pyontutils-9999.ebuild
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{10..12} pypy3 )
inherit distutils-r1
if [[ ${PV} == "9999" ]]; then
EGIT_REPO_URI="https://github.com/tgbugs/${PN}.git"
inherit git-r3
KEYWORDS=""
BDEPEND="app-editors/emacs"
else
inherit pypi
KEYWORDS="~amd64 ~x86"
fi
DESCRIPTION="utilities for working with the NIF ontology, SciGraph, and turtle"
HOMEPAGE="https://github.com/tgbugs/pyontutils"
LICENSE="MIT"
SLOT="0"
IUSE="dev -minimal -ontload spell test"
RESTRICT="
!test? ( test )
"
BDEPEND="${BDEPEND}
dev-python/fastentrypoints[${PYTHON_USEDEP}]"
RDEPEND="
>=dev-python/augpathlib-0.0.31[${PYTHON_USEDEP}]
dev-python/clifn[${PYTHON_USEDEP}]
dev-python/colorlog[${PYTHON_USEDEP}]
dev-python/docopt[${PYTHON_USEDEP}]
dev-python/funowl[${PYTHON_USEDEP}]
dev-python/gitpython[${PYTHON_USEDEP}]
dev-python/google-api-python-client[${PYTHON_USEDEP}]
dev-python/google-auth-oauthlib[${PYTHON_USEDEP}]
dev-python/htmlfn[${PYTHON_USEDEP}]
>=dev-python/idlib-0.0.1_pre15[${PYTHON_USEDEP}]
>=dev-python/joblib-1.1.0[${PYTHON_USEDEP}]
dev-python/lxml[${PYTHON_USEDEP}]
dev-python/nest-asyncio[${PYTHON_USEDEP}]
>=dev-python/ontquery-0.2.11[${PYTHON_USEDEP}]
>=dev-python/orthauth-0.0.16[${PYTHON_USEDEP}]
dev-python/pyld[${PYTHON_USEDEP}]
dev-python/pyyaml[${PYTHON_USEDEP}]
dev-python/requests[${PYTHON_USEDEP}]
dev-python/setuptools[${PYTHON_USEDEP}]
dev-python/terminaltables[${PYTHON_USEDEP}]
>=dev-python/ttlser-1.1.4[${PYTHON_USEDEP}]
dev-python/terminaltables[${PYTHON_USEDEP}]
dev? (
dev-python/pytest-cov[${PYTHON_USEDEP}]
dev-python/wheel[${PYTHON_USEDEP}]
)
ontload? (
dev-java/scigraph-bin[core]
)
spell? (
app-text/hunspell
)
test? (
dev-python/pytest[${PYTHON_USEDEP}]
)
"
distutils_enable_tests pytest
if [[ ${PV} == "9999" ]]; then
src_configure () { DISTUTILS_ARGS=( --release ); }
src_prepare () {
sed -i '1 i\import fastentrypoints' setup.py
# replace package version to keep python quiet
sed -i "s/__version__.\+$/__version__ = '9999.0.0+$(git rev-parse --short HEAD)'/" ${PN}/__init__.py
default
}
else
src_prepare () {
sed -i '1 i\import fastentrypoints' setup.py
default
}
fi
python_test() {
esetup.py install_data
epytest || die "Tests fail with ${EPYTHON}"
}
python_install_all() {
local DOCS=( README* docs/* )
distutils-r1_python_install_all
}