From 35a3022373a424e99db29a84063d0511ffcefac9 Mon Sep 17 00:00:00 2001 From: Albert Cheng Date: Tue, 29 Aug 2006 06:19:11 -0500 Subject: [svn-r12636] Purpose: Improve default settings. Use mpicc, mpif90, mpirun as the default $CC, $FC, and $RUNPARALLEL if enable-parallel. Tested: in TG-NCSA both serial and parallel. --- config/ia64-linux-gnu | 25 ++++++++++++++++++++----- 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/config/ia64-linux-gnu b/config/ia64-linux-gnu index 931201c..80e5317 100644 --- a/config/ia64-linux-gnu +++ b/config/ia64-linux-gnu @@ -18,9 +18,20 @@ # the various compile modes. # Use Intel C compiler by default (if it's available). -if test "X$CC" = "X" && which icc > /dev/null; then - CC=icc - CC_BASENAME=icc +# Use mpicc for parallel by default. +if test "X$CC" = "X"; then + if test "X-$enable_parallel" = "X-yes"; then + CC=mpicc + CC_BASENAME=mpicc + elif which icc > /dev/null; then + CC=icc + CC_BASENAME=icc + fi +fi + +# Define RUNPARALLEL if parallel mode is enabled or a parallel compiler used. +if test "X-$enable_parallel" = "X-yes" -o X-$CC_BASENAME = X-mpicc; then + RUNPARALLEL=${RUNPARALLEL="mpirun -np \$\${NPROCS:=3}"} fi #---------------------------------------------------------------------------- @@ -51,8 +62,12 @@ esac # The default Fortran 90 compiler # Use Intel Fortran compiler by default. -if test "X-$FC" = "X-"; then - FC="ifort" +if test X-$enable_fortran = X-yes -a "X-$FC" = "X-"; then + if test "X-$enable_parallel" = "X-yes"; then + FC=mpif90 + else + FC="ifort" + fi fi case $FC in -- cgit v0.12