From cc69b42e72fa8d61aa5f9e67a19e6a2d9017578d Mon Sep 17 00:00:00 2001 From: Gilles Gouaillardet Date: Mon, 5 Oct 2015 08:45:40 +0900 Subject: [PATCH] fortran: do not build the f08 bindings if PMPI is not built (back-ported from commit open-mpi/ompi@2d1a8fa920325b785553abce0b3408010d1f5b6b) (back-ported from commit open-mpi/ompi@e875f978c4790b71885e883dc346d87808610978) --- config/ompi_setup_mpi_fortran.m4 | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/config/ompi_setup_mpi_fortran.m4 b/config/ompi_setup_mpi_fortran.m4 index 62ee218d8a..0a0259d980 100644 --- a/config/ompi_setup_mpi_fortran.m4 +++ b/config/ompi_setup_mpi_fortran.m4 @@ -348,13 +348,22 @@ AC_DEFUN([OMPI_SETUP_MPI_FORTRAN],[ # We need to have ignore TKR functionality to build the mpi_f08 # module - AS_IF([test $OMPI_WANT_FORTRAN_USEMPIF08_BINDINGS -eq 1 && + AS_IF([test $OMPI_WANT_FORTRAN_USEMPIF08_BINDINGS -eq 1 && \ test $OMPI_FORTRAN_HAVE_IGNORE_TKR -eq 1], [OMPI_BUILD_FORTRAN_USEMPIF08_BINDINGS=1 OMPI_FORTRAN_F08_PREDECL=$OMPI_FORTRAN_IGNORE_TKR_PREDECL OMPI_FORTRAN_F08_TYPE=$OMPI_FORTRAN_IGNORE_TKR_TYPE ]) + AS_IF([test $OMPI_WANT_FORTRAN_USEMPIF08_BINDINGS -eq 1 && \ + test $OMPI_BUILD_FORTRAN_USEMPIF08_BINDINGS -eq 1], + [ # If we don't have PMPI, we won't build mpi_f08 at all + AC_MSG_CHECKING([whether PMPI is enabled]) + AS_IF([test "$WANT_MPI_PROFILING" -eq 1], + [AC_MSG_RESULT([yes])], + [OMPI_BUILD_FORTRAN_USEMPIF08_BINDINGS=0 + AC_MSG_RESULT([no])])]) + # The overall "_BIND_C" variable will be set to 1 if we have all # the necessary forms of BIND(C) OMPI_FORTRAN_HAVE_BIND_C=0