summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Fan <alex.fan.q@gmail.com>2023-01-06 20:55:13 +0800
committerYixun Lan <dlan@gentoo.org>2023-01-06 22:45:19 +0800
commitd714c01d6241f43dae4fb3abc426397d7609c622 (patch)
tree741e9c73d0f923e8d27cf5187b230e50a5bdb6a5 /dev-python/mpi4py
parentsci-geosciences/josm-bin: Stabilize 18583 amd64, #889940 (diff)
downloadgentoo-d714c01d6241f43dae4fb3abc426397d7609c622.tar.gz
gentoo-d714c01d6241f43dae4fb3abc426397d7609c622.tar.bz2
gentoo-d714c01d6241f43dae4fb3abc426397d7609c622.zip
dev-python/mpi4py: add 3.1.4
remove unneeded dev-python/nose dep, this package uses unittest bump PYTHON_COMPAT to 3.11 Signed-off-by: Alex Fan <alex.fan.q@gmail.com> Signed-off-by: Yixun Lan <dlan@gentoo.org>
Diffstat (limited to 'dev-python/mpi4py')
-rw-r--r--dev-python/mpi4py/Manifest1
-rw-r--r--dev-python/mpi4py/mpi4py-3.1.4.ebuild62
2 files changed, 63 insertions, 0 deletions
diff --git a/dev-python/mpi4py/Manifest b/dev-python/mpi4py/Manifest
index 7e2384ad85d3..faba9600f3e6 100644
--- a/dev-python/mpi4py/Manifest
+++ b/dev-python/mpi4py/Manifest
@@ -1 +1,2 @@
DIST mpi4py-3.1.3.tar.gz 2461368 BLAKE2B 3ff7f6519a1ee96249567b1c65401fd1242c433bbb0a55c9d0a9b07f167ec44c71aefc24ac5fb354ceeb591dbfe97a4306f8455bb00559789367e91b78d80c16 SHA512 7a15224692016253120e8e88be1f7201e6f4548c1fb5ed15f04f416000b0d9e259dd8e80c0e237b1a960143e52b4a840d2a541359833387ac12868af1c059cea
+DIST mpi4py-3.1.4.tar.gz 2493282 BLAKE2B e1a048e6053263f6685c549e2e6f96072b7d95db68595c8848d0ecdb0a6cadf2b102e4c4ce589053ed17a090335afc56f4b3630b60944aeac7e4bc4ad82d4a1b SHA512 f59ad765bc272f8b63f74cfde4e588f640c4fc3d47d05729509da45a2155f830c1d409ec716ff374756748fa8ebfa6e72f9fbe188a6b89ea3fa115740a532b08
diff --git a/dev-python/mpi4py/mpi4py-3.1.4.ebuild b/dev-python/mpi4py/mpi4py-3.1.4.ebuild
new file mode 100644
index 000000000000..85ed88fe6299
--- /dev/null
+++ b/dev-python/mpi4py/mpi4py-3.1.4.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..11} )
+inherit distutils-r1
+
+DESCRIPTION="Message Passing Interface for Python"
+HOMEPAGE="https://github.com/mpi4py/mpi4py https://pypi.org/project/mpi4py/"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~riscv ~x86 ~amd64-linux ~x86-linux"
+IUSE="doc examples test"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ dev-python/cython[${PYTHON_USEDEP}]
+ dev-python/numpy[${PYTHON_USEDEP}]
+ virtual/mpi
+"
+DEPEND="${RDEPEND}
+ test? (
+ virtual/mpi[romio]
+ )
+"
+
+DISTUTILS_IN_SOURCE_BUILD=1
+
+python_prepare_all() {
+ # not needed on install
+ rm -vr docs/source || die
+ rm test/test_pickle.py || die # disabled by Gentoo-bug #659348
+ distutils-r1_python_prepare_all
+}
+
+src_compile() {
+ export FAKEROOTKEY=1
+ distutils-r1_src_compile
+}
+
+python_test() {
+ echo "Beginning test phase"
+ pushd "${BUILD_DIR}"/../ &> /dev/null || die
+ # spawn is not stable in OpenMPI 4
+ # https://github.com/jsquyres/ompi/pull/4#issuecomment-806897758
+ # oob_tcp_if_include lo is needed to allow test in systemd-nspawn container
+ mpiexec --use-hwthread-cpus --mca btl tcp,self --mca oob_tcp_if_include lo \
+ -n 1 "${PYTHON}" -B ./test/runtests.py -v \
+ --exclude="test_msgspec" --exclude="test_spawn" ||
+ die "Testsuite failed under ${EPYTHON}"
+ popd &> /dev/null || die
+}
+
+python_install_all() {
+ use doc && local HTML_DOCS=( docs/. )
+ use examples && local DOCS=( demo )
+ distutils-r1_python_install_all
+}