diff --git a/net/mpifx/Makefile b/net/mpifx/Makefile index b49ce4325cb3..338f8a3bde47 100644 --- a/net/mpifx/Makefile +++ b/net/mpifx/Makefile @@ -1,39 +1,36 @@ PORTNAME= mpifx -DISTVERSION= 1.5 -PORTREVISION= 1 +DISTVERSION= 1.6 CATEGORIES= net devel MAINTAINER= yuri@FreeBSD.org COMMENT= Modern Fortran wrappers around MPI routines WWW= https://github.com/dftbplus/mpifx LICENSE= BSD2CLAUSE LICENSE_FILE= ${WRKSRC}/LICENSE BUILD_DEPENDS= fypp:devel/py-fypp@${PY_FLAVOR} USES= cmake:testing fortran mpi:mpich python:build USE_GITHUB= yes GH_ACCOUNT= dftbplus CMAKE_ON= BUILD_SHARED_LIBS post-patch: ${REINPLACE_CMD} -e '/include(CTest)/d' ${WRKSRC}/CMakeLists.txt -post-test: # run test programs # at least one test crashes, see https://github.com/dftbplus/mpifx/issues/35 +post-test: # run test programs without mpirun (CTest disabled, see https://github.com/dftbplus/mpifx/issues/49) .for f in test_allgather test_allgatherv test_allreduce test_bcast test_comm_split test_gather test_gatherv test_reduce test_scatter test_scatterv cd ${BUILD_WRKSRC}/test && ./${f} .endfor .include .if ${FORTRAN_DEFAULT} == gfortran && ${GCC_DEFAULT} >= 10 # workaround for Type mismatch in argument 'cc' at (1); passed COMPLEX(8) to REAL(8) FFLAGS+= -fallow-argument-mismatch .endif -# tests fail to run: https://github.com/dftbplus/mpifx/issues/49 - .include diff --git a/net/mpifx/distinfo b/net/mpifx/distinfo index c69546ded5ef..ae9cbf0079bb 100644 --- a/net/mpifx/distinfo +++ b/net/mpifx/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1710350639 -SHA256 (dftbplus-mpifx-1.5_GH0.tar.gz) = 3801cbd6134b30f403b59346b40ff5bfb47ebe125892cf483e78b477c20b1b02 -SIZE (dftbplus-mpifx-1.5_GH0.tar.gz) = 62405 +TIMESTAMP = 1778683451 +SHA256 (dftbplus-mpifx-1.6_GH0.tar.gz) = 5ec9bcb7b4d943109dddda2bec7ae29b82b9d5653566543ee451e75c76c8c3e1 +SIZE (dftbplus-mpifx-1.6_GH0.tar.gz) = 63414 diff --git a/net/mpifx/files/patch-test_test__comm__split.f90 b/net/mpifx/files/patch-test_test__comm__split.f90 new file mode 100644 index 000000000000..52b1d6036683 --- /dev/null +++ b/net/mpifx/files/patch-test_test__comm__split.f90 @@ -0,0 +1,16 @@ +-- Fix division by zero (SIGFPE) when running with a single MPI process. +-- With size=1, groupsize = 1/2 = 0 causes an integer divide-by-zero in the +-- next line. Use max(1, ...) to guard against that. +-- https://github.com/dftbplus/mpifx/issues/35 + +--- test/test_comm_split.f90.orig 2026-05-13 15:13:45 UTC ++++ test/test_comm_split.f90 +@@ -7,7 +7,7 @@ program test_comm_split + + call mpifx_init() + call allproc%init() +- groupsize = allproc%size / 2 ++ groupsize = max(1, allproc%size / 2) + mygroup = allproc%rank / groupsize + call allproc%split(mygroup, allproc%rank, groupproc) + write(*, "(3(A,1X,I0,1X))") "GLOBAL ID:", allproc%rank, "SUBGROUP", &