Fix: Circumvent problems with MPI_VERSION beeing set by MPI modules.

This commit is contained in:
Christoph Niethammer 2011-03-15 15:30:00 +00:00
parent 892119a768
commit d5d79905b9

5
sit
View file

@ -70,7 +70,8 @@ export ${COMPILER_OPTS}
if [ ! -z "$MPI" ] ; then
MPI_MODULE="mpi/$MPI"
if [ ! -z "$MPI_VERSION" ] ; then
MPI_MODULE=${MPI_MODULE}${MPI_VERSION:+"/${MPI_VERSION%%-*}-$COMPILER-$COMPILER_VERSION"}
MPI_VERSION_NUM=${MPI_VERSION%%-*}
MPI_MODULE=${MPI_MODULE}${MPI_VERSION_NUM:+"/${MPI_VERSION_NUM}-$COMPILER-$COMPILER_VERSION"}
fi
echo "Loading MPI module ${MPI_MODULE}"
module load $MPI_MODULE
@ -90,7 +91,7 @@ fi
# construct the final installation directory path
PREFIX="${PREFIX_BASE}/${CATEGORY}/${PACKAGE}/${VERSION}"
PREFIX_SUFFIX=${MPI:+"-$MPI"}${MPI_VERSION:+"-$MPI_VERSION"}
PREFIX_SUFFIX=${MPI:+"-$MPI"}${MPI_VERSION_NUM:+"-$MPI_VERSION_NUM"}
PREFIX_SUFFIX=$PREFIX_SUFFIX${COMPILER:+"-$COMPILER"}${COMPILER_VERSION:+"-$COMPILER_VERSION"}
PREFIX_SUFFIX=$PREFIX_SUFFIX${PACKAGE_DESCRIPTOR}