Gentoo Archives: gentoo-commits

From: "Michał Górny" <mgorny@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/regex/
Date: Tue, 30 Oct 2018 09:33:15
Message-Id: 1540891938.b0236ec7c52e3b15f1c97cdeab7844325ded1f1b.mgorny@gentoo
1 commit: b0236ec7c52e3b15f1c97cdeab7844325ded1f1b
2 Author: Nils Freydank <holgersson <AT> posteo <DOT> de>
3 AuthorDate: Sat Oct 27 17:54:10 2018 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Tue Oct 30 09:32:18 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b0236ec7
7
8 dev-python/regex: Add pypy3 support
9
10 Signed-off-by: Nils Freydank <holgersson <AT> posteo.de>
11 Package-Manager: Portage-2.3.51, Repoman-2.3.11
12 Pull-Request: https://github.com/gentoo/gentoo/pull/10166
13 Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
14
15 dev-python/regex/regex-2017.04.05-r1.ebuild | 45 +++++++++++++++++++++++++++++
16 1 file changed, 45 insertions(+)
17
18 diff --git a/dev-python/regex/regex-2017.04.05-r1.ebuild b/dev-python/regex/regex-2017.04.05-r1.ebuild
19 new file mode 100644
20 index 00000000000..f67aa62e686
21 --- /dev/null
22 +++ b/dev-python/regex/regex-2017.04.05-r1.ebuild
23 @@ -0,0 +1,45 @@
24 +# Copyright 1999-2018 Gentoo Authors
25 +# Distributed under the terms of the GNU General Public License v2
26 +
27 +EAPI=7
28 +
29 +PYTHON_COMPAT=( python2_7 python3_{4,5,6,7} pypy pypy3 )
30 +
31 +inherit distutils-r1 flag-o-matic
32 +
33 +DESCRIPTION="Alternative regular expression module to replace re"
34 +HOMEPAGE="https://bitbucket.org/mrabarnett/mrab-regex"
35 +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
36 +
37 +LICENSE="Apache-2.0"
38 +SLOT="0"
39 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-fbsd"
40 +IUSE="doc"
41 +
42 +DOCS=( README docs/UnicodeProperties.txt )
43 +
44 +python_compile() {
45 + if ! python_is_python3; then
46 + local CFLAGS=${CFLAGS}
47 + append-cflags -fno-strict-aliasing
48 + fi
49 + distutils-r1_python_compile
50 +}
51 +
52 +python_test() {
53 + local msg="tests failed under ${EPYTHON}"
54 + # https://bitbucket.org/mrabarnett/mrab-regex/issue/145/1-fail-in-testsuite-under-pypy
55 + einfo "There is one trivial fail of test test_empty_array under pypy"
56 +
57 + if python_is_python3; then
58 + "${PYTHON}" Python3/test_regex.py || die "${msg}"
59 + else
60 + "${PYTHON}" Python2/test_regex.py || die "${msg}"
61 + fi
62 +}
63 +
64 +python_install_all() {
65 + use doc && local HTML_DOCS=( docs/Features.html )
66 +
67 + distutils-r1_python_install_all
68 +}