diff options
| author | Liguros - Gitlab CI/CD [develop] <gitlab@liguros.net> | 2024-11-28 06:47:13 +0000 |
|---|---|---|
| committer | Liguros - Gitlab CI/CD [develop] <gitlab@liguros.net> | 2024-11-28 06:47:13 +0000 |
| commit | 7606a5827d7daf24efdab80c9c79f5beee92853a (patch) | |
| tree | 98c5f7fd4cbb7db2bf7bdff350138c06a4049f0d /dev-python/mpi4py | |
| parent | 97f43cfdccfced2ff9c18a57619b7e586fb3e1a3 (diff) | |
| download | baldeagleos-repo-7606a5827d7daf24efdab80c9c79f5beee92853a.tar.gz baldeagleos-repo-7606a5827d7daf24efdab80c9c79f5beee92853a.tar.xz baldeagleos-repo-7606a5827d7daf24efdab80c9c79f5beee92853a.zip | |
Adding metadata
Diffstat (limited to 'dev-python/mpi4py')
| -rw-r--r-- | dev-python/mpi4py/Manifest | 1 | ||||
| -rw-r--r-- | dev-python/mpi4py/files/mpi4py-4-mpich-no-fortran-fix.patch | 20 | ||||
| -rw-r--r-- | dev-python/mpi4py/files/mpi4py-4-use-mesonpy.patch | 11 | ||||
| -rw-r--r-- | dev-python/mpi4py/metadata.xml | 3 | ||||
| -rw-r--r-- | dev-python/mpi4py/mpi4py-4.0.1.ebuild | 80 |
5 files changed, 114 insertions, 1 deletions
diff --git a/dev-python/mpi4py/Manifest b/dev-python/mpi4py/Manifest index 19f3f4338db2..e6e8c8e82532 100644 --- a/dev-python/mpi4py/Manifest +++ b/dev-python/mpi4py/Manifest @@ -1 +1,2 @@ DIST mpi4py-3.1.5.tar.gz 2469777 BLAKE2B 0638e3def52f731b64e2999f83f2d6ccc94dc2f8b37d964c10e49ca12470d3d3ef77ff2737294d85614b2d59d1eec49880e74f2ba3d73fd090152b63c8cc701e SHA512 04da1d6daf66cc86fa3ec574eea6e01749f895035e3394afbc68d6245394c5b03557ede0bda3642b06d9c6ff2c1e6e878a6c8c30d3fa3491392e2e13b82cdec8 +DIST mpi4py-4.0.1.tar.gz 466179 BLAKE2B 4e678f08c257a32922914448c82d13c0a1e29aa1e39a1f669d8c2d766a1ecbd8bdf2bf3b12dae8eca9bf3846c096d0ecb0bbdb9147b3048acfe48e067d72161f SHA512 7721ef4f0859e90ca91d6911c3e5a897249f57c8b575065cdb1d537602ce0b30909f144b292c7d74013361cdf9e464cb0c16e408f37fd6c8c1554cbbe9785c05 diff --git a/dev-python/mpi4py/files/mpi4py-4-mpich-no-fortran-fix.patch b/dev-python/mpi4py/files/mpi4py-4-mpich-no-fortran-fix.patch new file mode 100644 index 000000000000..82415dae491d --- /dev/null +++ b/dev-python/mpi4py/files/mpi4py-4-mpich-no-fortran-fix.patch @@ -0,0 +1,20 @@ +diff --git a/src/lib-mpi/compat/mpich.h b/src/lib-mpi/compat/mpich.h +index 2cd50c1..3ea9510 100644 +--- a/src/lib-mpi/compat/mpich.h ++++ b/src/lib-mpi/compat/mpich.h +@@ -123,7 +123,6 @@ static int PyMPI_MPICH_MPI_Reduce_c(const void *sendbuf, void *recvbuf, + + /* -------------------------------------------------------------------------- */ + +-#if defined(CIBUILDWHEEL) + + #define PyMPI_MPICH_CALL_WEAK_SYMBOL(function, ...) \ + if (function) return function(__VA_ARGS__); \ +@@ -159,7 +158,6 @@ static int PyMPI_MPICH_MPI_Status_f2c(const MPI_Fint *fs, MPI_Status *cs) + { PyMPI_MPICH_CALL_WEAK_SYMBOL(MPI_Status_f2c, fs, cs); } + #define MPI_Status_f2c PyMPI_MPICH_MPI_Status_f2c + +-#endif + + /* -------------------------------------------------------------------------- */ + diff --git a/dev-python/mpi4py/files/mpi4py-4-use-mesonpy.patch b/dev-python/mpi4py/files/mpi4py-4-use-mesonpy.patch new file mode 100644 index 000000000000..f8ba9bd474f5 --- /dev/null +++ b/dev-python/mpi4py/files/mpi4py-4-use-mesonpy.patch @@ -0,0 +1,11 @@ +diff --git a/pyproject.toml b/pyproject.toml +index 8585f6d..5b0b2d8 100644 +--- a/pyproject.toml ++++ b/pyproject.toml +@@ -1,4 +1,3 @@ + [build-system] +-requires = ["setuptools >= 42", "build"] +-build-backend = "builder" +-backend-path = ["conf"] ++requires = ["meson-python", "Cython"] ++build-backend = "mesonpy" diff --git a/dev-python/mpi4py/metadata.xml b/dev-python/mpi4py/metadata.xml index f2400a768382..43291824ab23 100644 --- a/dev-python/mpi4py/metadata.xml +++ b/dev-python/mpi4py/metadata.xml @@ -9,7 +9,8 @@ <email>proxy-maint@gentoo.org</email> <name>Proxy Maintainers</name> </maintainer> - <longdescription lang="en">MPI for Python (mpi4py) provides bindings of the Message Passing + <longdescription lang="en"> + MPI for Python (mpi4py) provides bindings of the Message Passing Interface (MPI) standard for the Python programming language, allowing any Python program to exploit multiple processors. This package is constructed on top of the MPI-1/MPI-2 specification diff --git a/dev-python/mpi4py/mpi4py-4.0.1.ebuild b/dev-python/mpi4py/mpi4py-4.0.1.ebuild new file mode 100644 index 000000000000..26528d361226 --- /dev/null +++ b/dev-python/mpi4py/mpi4py-4.0.1.ebuild @@ -0,0 +1,80 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{9,10,11,12,13} ) +DISTUTILS_EXT=1 +DISTUTILS_USE_PEP517=meson-python +inherit distutils-r1 pypi + +DESCRIPTION="Message Passing Interface for Python" +HOMEPAGE=" + https://github.com/mpi4py/mpi4py + https://pypi.org/project/mpi4py/ +" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~riscv ~x86 ~amd64-linux ~x86-linux" +IUSE="doc examples" + +RDEPEND=" + dev-python/numpy[${PYTHON_USEDEP}] + virtual/mpi +" +DEPEND="${RDEPEND}" + +BDEPEND=" + dev-python/cython[${PYTHON_USEDEP}] + >=dev-build/meson-1.0.0 + virtual/mpi +" + +PATCHES=( + "${FILESDIR}/${PN}-4-use-mesonpy.patch" + "${FILESDIR}/${PN}-4-mpich-no-fortran-fix.patch" +) + +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 +} + +python_compile() { + export CC=mpicc + distutils-r1_python_compile +} + +python_test() { + echo "Beginning test phase" + local -x PYTHONPATH="${BUILD_DIR}/install$(python_get_sitedir)" + + # python want's all arguments as separate strings + local mpi_opts=( + "-n" "1" + ) + if has_version sys-cluster/openmpi; then + local mpi_opts+=( + "--use-hwthread-cpus" + # allow test in systemd-nspawn container + "--mca" "btl" "tcp,self" + "--mca" "oob_tcp_if_include" "lo" + # disable openmpi OSC UCX component + # https://github.com/open-mpi/ompi/issues/12517 + "--mca" "osc" "^ucx" + ) + fi + mpiexec \ + "${mpi_opts[@]}" \ + "${PYTHON}" -B -v ./test/runtests.py -v || + die "Testsuite failed under ${EPYTHON}" +} + +python_install_all() { + use doc && local HTML_DOCS=( docs/. ) + use examples && local DOCS=( demo ) + distutils-r1_python_install_all +} |
