build_all_variants 463 Bytes
Newer Older
gsell's avatar
gsell committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
#!/bin/bash

declare -r basedir=$(dirname $0)
source '../../config/Pmodules.conf'

declare -r recipe="${basedir}/$1/build"
shift

if [[ ! -x "${recipe}" ]]; then
	echo "Error: no recipe to build '$1'!"
	exit 1
fi

for cc in "${COMPILER_VERSIONS[@]}"; do
	for mpi in "${MPI_VERSIONS[@]}"; do
		"${recipe}" "$@" --with=$cc --with=$mpi || {
			echo "Oops: build failed for:"
			echo "        compiler: $cc"
			echo "        mpi:      $mpi"
20
			exit 1
gsell's avatar
gsell committed
21 22 23
			}
	done
done