summaryrefslogtreecommitdiffstats
path: root/m4/aclocal_fc.m4
diff options
context:
space:
mode:
Diffstat (limited to 'm4/aclocal_fc.m4')
-rw-r--r--m4/aclocal_fc.m427
1 files changed, 27 insertions, 0 deletions
diff --git a/m4/aclocal_fc.m4 b/m4/aclocal_fc.m4
index 7e909ba..04bcf5f 100644
--- a/m4/aclocal_fc.m4
+++ b/m4/aclocal_fc.m4
@@ -249,3 +249,30 @@ rm -rf conftest*
AC_LANG_POP(Fortran)
])
+dnl ----------------------
+dnl Parallel Test Programs
+dnl ----------------------
+
+dnl Try link a simple MPI program.
+
+AC_DEFUN([PAC_PROG_FC_MPI_CHECK],[
+
+dnl Change to the Fortran 90 language
+ AC_LANG_PUSH(Fortran)
+
+dnl Try link a simple MPI program.
+ AC_MSG_CHECKING([whether a simple MPI-IO Fortran program can be linked])
+ AC_LINK_IFELSE([
+ PROGRAM main
+ USE mpi
+ INTEGER :: ierr
+ call mpi_file_open( ierr )
+ END],
+ [AC_MSG_RESULT([yes])],
+ [AC_MSG_RESULT([no])
+ AC_MSG_ERROR([unable to link a simple MPI-IO Fortran program])])
+
+dnl Change to the C language
+ AC_LANG_POP(Fortran)
+])
+