Allow specification of different mpirun to be used by the RunFunctions - Used on Mac but may be beneficial for other systems too
This commit is contained in:
parent
d868141816
commit
1cb3e1f77a
2 changed files with 20 additions and 2 deletions
|
@ -75,7 +75,14 @@ runParallel ()
|
|||
echo "$APP_NAME already run on $PWD: remove log file to run"
|
||||
else
|
||||
echo "Running $APP_NAME in parallel on $PWD using $1 processes"
|
||||
( mpirun -np $1 $APP_RUN -parallel < /dev/null > $LOG_NAME 2>&1 )
|
||||
if [ -z "$WM_MPIRUN_PROG" ]
|
||||
then
|
||||
mpirunProg=mpirun
|
||||
else
|
||||
# Allow exceentric systems to override the hardcoded mpirun
|
||||
mpirunProg=$WM_MPIRUN_PROG
|
||||
fi
|
||||
( $mpirunProg -np $1 $APP_RUN -parallel < /dev/null > $LOG_NAME 2>&1 )
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
|
@ -248,7 +248,13 @@ MACPORTOPENMPI)
|
|||
export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/$FOAM_MPI
|
||||
_foamAddLib $libDir
|
||||
unset libDir
|
||||
;;
|
||||
|
||||
which mpirun >/dev/null
|
||||
if [ $? -ne 0 ]
|
||||
then
|
||||
export WM_MPIRUN_PROG=mpirun-openmpi-$WM_MACPORT_MPI_VERSION
|
||||
fi
|
||||
;;
|
||||
|
||||
MACPORTMPICH)
|
||||
export FOAM_MPI=mpich-macports-$WM_MACPORT_MPI_VERSION
|
||||
|
@ -260,6 +266,11 @@ MACPORTMPICH)
|
|||
_foamAddLib $libDir
|
||||
unset libDir
|
||||
|
||||
which mpirun >/dev/null
|
||||
if [ $? -ne 0 ]
|
||||
then
|
||||
export WM_MPIRUN_PROG=mpirun-mpich-$WM_MACPORT_MPI_VERSION
|
||||
fi
|
||||
;;
|
||||
|
||||
SYSTEMOPENMPI)
|
||||
|
|
Reference in a new issue