From 604dc9744b1ef4b9a6428ca99ef7d5b5d9a33ee7 Mon Sep 17 00:00:00 2001 From: KAWASHIMA Takahiro Date: Wed, 26 Dec 2018 13:37:12 +0900 Subject: [PATCH] ompi_ext.m4: Allow generated MPI-ext Fortran headers Allow MPI extensions to generate Fortran headers using Autoconf. For example, allow following files. ``` ompi/mpiext/example/mpif-h/mpiext_example_mpifh.h.in ompi/mpiext/example/use-mpi/mpiext_example_usempi.h.in ompi/mpiext/example/use-mpi-f08/mpiext_example_usempif08.h.in ``` Generated MPI extension C headers are already allowed in commit 6a7d5271c4. Signed-off-by: KAWASHIMA Takahiro --- config/ompi_ext.m4 | 27 ++++++++++++++++++++------- 1 file changed, 20 insertions(+), 7 deletions(-) diff --git a/config/ompi_ext.m4 b/config/ompi_ext.m4 index 827658e6db..88001e0142 100644 --- a/config/ompi_ext.m4 +++ b/config/ompi_ext.m4 @@ -506,7 +506,7 @@ EOF AC_MSG_CHECKING([if MPI Extension $component has mpif.h bindings]) - if test -e "$test_header" ; then + if test -e "$test_header" || test -e "$test_header".in ; then AC_MSG_RESULT([yes]) enabled_mpifh=1 @@ -541,6 +541,10 @@ EOF AC_MSG_ERROR([Cannot continue])]) component_header="mpiext_${component}_mpifh.h" + mpifh_component_header_path="ompi/mpiext/$component/mpif-h/${component_header}" + if test -e "${srcdir}/${mpifh_component_header_path}" ; then + mpifh_component_header_path="${srcdir}/${mpifh_component_header_path}" + fi cat >> $mpif_ext_h <> $mpiusempi_ext_h <> $mpiusempi_ext_h <> $mpiusempi_ext_h <> $mpiusempif08_ext_h <> $mpiusempif08_ext_h <> $mpiusempif08_ext_h <