freebsd-ports/net/py-mpi4py/Makefile
Laurent Chardon 907f3f00bc net/py-mpi4py: Update 3.1.6 → 4.0.0
Backward-incompatible changes:
  * Python 2 is no longer supported, Python 3.6+ is required, but
    typing stubs are supported for Python 3.8+.
  * The Intracomm.Create_group() method is no longer defined in the
    base Comm class.
  * Group.Compare() and Comm.Compare() are no longer class methods
    but instance methods. Existing codes using the former class
    methods are expected to continue working.
  * Group.Translate_ranks() is no longer a class method but an
    instance method. Existing codes using the former class method are
    expected to continue working.
  * The LB and UB datatypes are no longer available, use
    Datatype.Create_resized() instead.
  * The HOST predefined attribute key is no longer available.
  * The MPI.memory class has been renamed to MPI.buffer. The old
    name is still available as an alias to the new name.
  * The mpi4py.dl module is no longer available.
  * The mpi4py.get_config function returns an empty dictionary.

Changelog:
https://github.com/mpi4py/mpi4py/releases/tag/4.0.0

Exp-run looks fine.

Take maintainership.

PR:	280883
2024-09-01 18:57:59 +03:00

55 lines
1.3 KiB
Makefile

PORTNAME= mpi4py
DISTVERSION= 4.0.0
CATEGORIES= net parallel python
MASTER_SITES= PYPI
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
MAINTAINER= laurent.chardon@gmail.com
COMMENT?= Python bindings for MPI (OpenMPI)
WWW= https://github.com/mpi4py/mpi4py
LICENSE= BSD3CLAUSE
LICENSE_FILE= ${WRKSRC}/LICENSE.rst
BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}cython3>3.0.0:lang/cython3@${PY_FLAVOR}
USES= pkgconfig python
USE_PYTHON= autoplist concurrent distutils
MP?= OPENMPI
.if ${MP} == "OPENMPI"
USES+= mpi:openmpi
CONFLICTS_INSTALL= ${PYTHON_PKGNAMEPREFIX}mpi4py-mpich-4*
.elif ${MP} == "MPICH"
USES+= fortran mpi:mpich
LDFLAGS+= ${LOCALBASE}/lib/gcc${GCC_DEFAULT}/libgcc_s.so
CONFLICTS_INSTALL= ${PYTHON_PKGNAMEPREFIX}mpi4py-4*
.else
BROKEN= invalid parameter MP
.endif
LDFLAGS+= ${MPI_LIBS}
#SLAVEDIRS= net/py-mpi4py-mpich
OPTIONS_DEFINE= DOCS
PORTDOCS= *
pre-configure:
${CP} ${FILESDIR}/mpi.cfg ${WRKSRC}/
${REINPLACE_CMD} -e 's|%%LOCALBASE%%/mpi/openmpi|${MPI_HOME}|' \
${WRKSRC}/mpi.cfg
do-install-DOCS-on:
${MKDIR} ${STAGEDIR}${DOCSDIR}
${INSTALL_DATA} ${WRKSRC}/README.rst ${STAGEDIR}${DOCSDIR}
(cd ${WRKSRC}/docs && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
post-install:
(cd ${STAGEDIR}${PYTHON_SITELIBDIR}/mpi4py && ${STRIP_CMD} *.so)
do-test:
(cd ${WRKSRC} && ${PYTHON_CMD} ${PYDISTUTILS_SETUP} test)
.include <bsd.port.mk>