1 |
commit: 0e9f06476106f3085395ef79413e4004e7d82a44 |
2 |
Author: Arfrever Frehtes Taifersar Arahesis <Arfrever <AT> Apache <DOT> Org> |
3 |
AuthorDate: Thu Apr 18 19:33:36 2019 +0000 |
4 |
Commit: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Apr 19 16:39:08 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0e9f0647 |
7 |
|
8 |
dev-python/protobuf-python: Add live ebuild. |
9 |
|
10 |
Signed-off-by: Arfrever Frehtes Taifersar Arahesis <Arfrever <AT> Apache.Org> |
11 |
Signed-off-by: Mike Gilbert <floppym <AT> gentoo.org> |
12 |
|
13 |
.../protobuf-python/protobuf-python-9999.ebuild | 62 ++++++++++++++++++++++ |
14 |
1 file changed, 62 insertions(+) |
15 |
|
16 |
diff --git a/dev-python/protobuf-python/protobuf-python-9999.ebuild b/dev-python/protobuf-python/protobuf-python-9999.ebuild |
17 |
new file mode 100644 |
18 |
index 00000000000..5eed49d3f29 |
19 |
--- /dev/null |
20 |
+++ b/dev-python/protobuf-python/protobuf-python-9999.ebuild |
21 |
@@ -0,0 +1,62 @@ |
22 |
+# Copyright 2008-2019 Arfrever Frehtes Taifersar Arahesis and others |
23 |
+# Distributed under the terms of the GNU General Public License v2 |
24 |
+ |
25 |
+EAPI="7" |
26 |
+PYTHON_COMPAT=(python{2_7,3_5,3_6,3_7}) |
27 |
+ |
28 |
+inherit distutils-r1 |
29 |
+ |
30 |
+if [[ "${PV}" == "9999" ]]; then |
31 |
+ inherit git-r3 |
32 |
+ |
33 |
+ EGIT_REPO_URI="https://github.com/protocolbuffers/protobuf" |
34 |
+ EGIT_SUBMODULES=() |
35 |
+fi |
36 |
+ |
37 |
+DESCRIPTION="Google's Protocol Buffers - Python bindings" |
38 |
+HOMEPAGE="https://developers.google.com/protocol-buffers/ https://github.com/protocolbuffers/protobuf" |
39 |
+if [[ "${PV}" == "9999" ]]; then |
40 |
+ SRC_URI="" |
41 |
+else |
42 |
+ SRC_URI="https://github.com/protocolbuffers/protobuf/archive/v${PV}.tar.gz -> protobuf-${PV}.tar.gz" |
43 |
+fi |
44 |
+ |
45 |
+LICENSE="BSD" |
46 |
+SLOT="0/18" |
47 |
+KEYWORDS="" |
48 |
+IUSE="" |
49 |
+ |
50 |
+BDEPEND="${PYTHON_DEPS} |
51 |
+ ~dev-libs/protobuf-${PV} |
52 |
+ dev-python/namespace-google[${PYTHON_USEDEP}] |
53 |
+ dev-python/setuptools[${PYTHON_USEDEP}] |
54 |
+ dev-python/six[${PYTHON_USEDEP}]" |
55 |
+DEPEND="${PYTHON_DEPS} |
56 |
+ ~dev-libs/protobuf-${PV}" |
57 |
+RDEPEND="${BDEPEND} |
58 |
+ !<dev-libs/protobuf-3[python(-)]" |
59 |
+ |
60 |
+S="${WORKDIR}/protobuf-${PV}/python" |
61 |
+ |
62 |
+if [[ "${PV}" == "9999" ]]; then |
63 |
+ EGIT_CHECKOUT_DIR="${WORKDIR}/protobuf-${PV}" |
64 |
+fi |
65 |
+ |
66 |
+python_configure_all() { |
67 |
+ mydistutilsargs=(--cpp_implementation) |
68 |
+} |
69 |
+ |
70 |
+python_compile() { |
71 |
+ python_is_python3 || local -x CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing" |
72 |
+ distutils-r1_python_compile |
73 |
+} |
74 |
+ |
75 |
+python_test() { |
76 |
+ esetup.py test |
77 |
+} |
78 |
+ |
79 |
+python_install_all() { |
80 |
+ distutils-r1_python_install_all |
81 |
+ |
82 |
+ find "${D}" -name "*.pth" -delete || die |
83 |
+} |