[mpich2-commits] r4050 - mpich2/trunk/test/mpi

chan at mcs.anl.gov chan at mcs.anl.gov
Fri Mar 13 00:15:32 CDT 2009


Author: chan
Date: 2009-03-13 00:15:31 -0500 (Fri, 13 Mar 2009)
New Revision: 4050

Modified:
   mpich2/trunk/test/mpi/configure.in
Log:
Fixed f77 and f90 build when the base f77/f90 compilers are naive compilers, i.e. not MPI wrapper compilers, by using the patch provided by David Gingold.  The patch resolves bug report req#425.  Also, fixed VPATH build for f77 and f90 support.



Modified: mpich2/trunk/test/mpi/configure.in
===================================================================
--- mpich2/trunk/test/mpi/configure.in	2009-03-13 01:52:57 UTC (rev 4049)
+++ mpich2/trunk/test/mpi/configure.in	2009-03-13 05:15:31 UTC (rev 4050)
@@ -206,6 +206,16 @@
         enable_f77=no
     fi    
 fi
+if test "$enable_f90" = yes ; then
+    AC_PROG_F90
+    if test -z "$BASEF90" ; then
+        BASEF90="$F90"
+    fi
+    # If there is no working F90, then set enable_f90 to no
+    if test -z "$F90" ; then
+        enable_f90=no
+    fi
+fi
 if test "$enable_cxx" = yes ; then
     AC_PROG_CXX
     if test -z "$BASECXX" ; then
@@ -255,6 +265,11 @@
     else
         F77=$MPIF77
     fi
+    if test -z "$MPIF90" ; then
+        F90=$with_mpi/bin/mpif90
+    else
+        F90=$MPIF90
+    fi
     if test -z "$MPICXX" ; then
         CXX=$with_mpi/bin/mpicxx
     else
@@ -591,6 +606,11 @@
     # MPI programs may require that the programs be run with mpiexec or
     # something similar (this is true for the IBM MPI, for example).
     rm -f f77/init/checksizes.c
+    # If it is a VPATH build, f77/init may not be there.
+    if test ! -d f77/init ; then
+        mkdir f77
+        mkdir f77/init
+    fi
     cat > f77/init/checksizes.c <<EOF
 #include "mpi.h"
 #include <stdio.h>
@@ -719,7 +739,9 @@
     elif test -z "$BASEF90" ; then
         BASEF90=$F90
     fi
-    F90=$saveF90
+    if test -n "$BASEF90" ; then
+        F90=$saveF90
+    fi
 fi
 
 if test "$enable_f90" = yes ; then
@@ -781,6 +803,11 @@
     fi
 
     if test -f f77/init/checksizes.c ; then
+        # If it is a VPATH build, f90/init may not be there.
+        if test ! -d f90/init ; then
+            mkdir f90
+            mkdir f90/init
+        fi
         cp f77/init/checksizes.c f90/init
     fi
 fi



More information about the mpich2-commits mailing list