Control: tags -1 patch On Mon, Jul 08, 2024 at 03:30:17PM -0500, Dirk Eddelbuettel wrote: > > On 8 July 2024 at 22:09, Sebastian Ramacher wrote: > | Source: rmpi > | Version: 0.7-2-1 > | Severity: serious > | Tags: ftbfs > | Justification: fails to build from source (but built successfully in the > past) > | X-Debbugs-Cc: sramac...@debian.org > | > | > https://buildd.debian.org/status/fetch.php?pkg=rmpi&arch=armel&ver=0.7-2-1%2Bb2&stamp=1720427935&raw=0 > | > | checking if pkg-config knows about OpenMPI... no > | checking for stdio.h... yes > | checking for stdlib.h... yes > | checking for string.h... yes > | checking for inttypes.h... yes > | checking for stdint.h... yes > | checking for strings.h... yes > | checking for sys/stat.h... yes > | checking for sys/types.h... yes > | checking for unistd.h... yes > | checking for mpi.h... no > | configure: error: "Cannot find mpi.h header file" > | ERROR: configuration failed for package ‘Rmpi’ > | * removing ‘/<<PKGBUILDDIR>>/debian/r-cran-rmpi/usr/lib/R/site-library/Rmpi’ > | dh_auto_install: error: R CMD INSTALL -l > /<<PKGBUILDDIR>>/debian/r-cran-rmpi/usr/lib/R/site-library --clean > --no-test-load . "--built-timestamp='Mon, 08 Jul 2024 08:38:43 +0000'" > returned exit code 1 > | make: *** [debian/rules:7: binary-arch] Error 25 > > :-/ > > R no linger supports i386 (and other 32 bt arches) upstream.
Neither does Open MPI, and the current transition to MPICH on 32bit is the relevant change that broke it. The good news is that rmpi does support MPICH, it only uses a very manual way when trying to find it - and that fails. The attached patch adds a pkg-config search to configure.ac (similar to what was already added for Open MPI above). > Dirk cu Adrian
Description: Try to find mpich with pkg-config if pkg-config did not find openmpi Author: Adrian Bunk <b...@debian.org> --- rmpi-0.7-2.orig/configure.ac +++ rmpi-0.7-2/configure.ac @@ -96,6 +96,11 @@ if test -z "$MPI_ROOT" ; then fi if test -z "$MPI_ROOT" ; then + #Use pkg-config to find mpich + PKG_CHECK_MODULES([MPICH],[mpich],[MPITYPE="MPICH" MPI_ROOT="NONEED"],[:]) +fi + +if test -z "$MPI_ROOT" ; then for d in /opt/lib /usr/lib /usr /usr/lib/x86_64-linux-gnu/openmpi \ /usr/local/lib /usr/local /usr/lib64/mpi/gcc/openmpi; do if test -f $d/include/mpi.h && test -d $d/lib/openmpi; then @@ -303,7 +308,12 @@ case "$MPITYPE" in PKG_LIBS="-L${MPI_LIBPATH} -lmpi -llam ${MPI_LIBS}" ;; MPICH) - PKG_LIBS="-L${MPI_LIBPATH} -lmpich -lmpl -lopa ${MPI_LIBS}" + if test "$MPI_ROOT" = "NONEED"; then + PKG_CPPFLAGS="${MPICH_CFLAGS}" + PKG_LIBS="${MPICH_LIBS}" + else + PKG_LIBS="-L${MPI_LIBPATH} -lmpich -lmpl -lopa ${MPI_LIBS}" + fi ;; MPICH2) PKG_LIBS="-L${MPI_LIBPATH} -lmpich -lmpl -lopa ${MPI_LIBS}"