Skip to content

Commit

Permalink
Update install_openmpi.sh
Browse files Browse the repository at this point in the history
This fixes a syntax error in case open-mpi is selected, but the mpirun command returns something unexpected like, e.g.:
"mpirun (IBM Spectrum MPI) 10.3.1.02rtm0"
This assumes mpi3 is available in such cases.
  • Loading branch information
frobnitzem authored and oschuett committed Feb 6, 2021
1 parent 67219d0 commit ad45b9e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tools/toolchain/scripts/stage1/install_openmpi.sh
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,8 @@ EOF
OPENMPI_LDFLAGS="${OPENMPI_LDFLAGS//-l${lib}}"
done
# old versions didn't support MPI 3, so adjust __MPI_VERSION accordingly (needed e.g. for pexsi)
if [ $major_version -lt 1 ] || \
[ $major_version -eq 1 -a $minor_version -lt 7 ] ; then
if [[ "$major_version" =~ ^[0-9]+$ ]] && ( [ $major_version -lt 1 ] || \
[ $major_version -eq 1 -a $minor_version -lt 7 ] ) ; then
mpi2_dflags="-D__MPI_VERSION=2"
else
mpi2_dflags=''
Expand Down

0 comments on commit ad45b9e

Please sign in to comment.