Merge branch 'develop' of https://github.com/LLNL/spack into fixes/intel_openmpi

This commit is contained in:
Massimiliano Culpo
2016-03-10 13:18:03 +01:00
106 changed files with 1808 additions and 909 deletions

50
lib/spack/env/cc vendored
View File

@@ -90,15 +90,15 @@ case "$command" in
command="$SPACK_CC"
language="C"
;;
c++|CC|g++|clang++|icpc|pgCC|xlc++)
c++|CC|g++|clang++|icpc|pgc++|xlc++)
command="$SPACK_CXX"
language="C++"
;;
f90|fc|f95|gfortran|ifort|pgf90|xlf90|nagfor)
f90|fc|f95|gfortran|ifort|pgfortran|xlf90|nagfor)
command="$SPACK_FC"
language="Fortran 90"
;;
f77|gfortran|ifort|pgf77|xlf|nagfor)
f77|gfortran|ifort|pgfortran|xlf|nagfor)
command="$SPACK_F77"
language="Fortran 77"
;;
@@ -138,7 +138,7 @@ if [ -z "$mode" ]; then
done
fi
# Dump the version and exist if we're in testing mode.
# Dump the version and exit if we're in testing mode.
if [ "$SPACK_TEST_COMMAND" = "dump-mode" ]; then
echo "$mode"
exit
@@ -187,32 +187,44 @@ while [ -n "$1" ]; do
;;
-Wl,*)
arg="${1#-Wl,}"
if [ -z "$arg" ]; then shift; arg="$1"; fi
if [[ "$arg" = -rpath=* ]]; then
rpaths+=("${arg#-rpath=}")
elif [[ "$arg" = -rpath ]]; then
# TODO: Handle multiple -Wl, continuations of -Wl,-rpath
if [[ $arg == -rpath=* ]]; then
arg="${arg#-rpath=}"
for rpath in ${arg//,/ }; do
rpaths+=("$rpath")
done
elif [[ $arg == -rpath,* ]]; then
arg="${arg#-rpath,}"
for rpath in ${arg//,/ }; do
rpaths+=("$rpath")
done
elif [[ $arg == -rpath ]]; then
shift; arg="$1"
if [[ "$arg" != -Wl,* ]]; then
if [[ $arg != '-Wl,'* ]]; then
die "-Wl,-rpath was not followed by -Wl,*"
fi
rpaths+=("${arg#-Wl,}")
arg="${arg#-Wl,}"
for rpath in ${arg//,/ }; do
rpaths+=("$rpath")
done
else
other_args+=("-Wl,$arg")
fi
;;
-Xlinker,*)
arg="${1#-Xlinker,}"
if [ -z "$arg" ]; then shift; arg="$1"; fi
if [[ "$arg" = -rpath=* ]]; then
-Xlinker)
shift; arg="$1";
if [[ $arg = -rpath=* ]]; then
rpaths+=("${arg#-rpath=}")
elif [[ "$arg" = -rpath ]]; then
elif [[ $arg = -rpath ]]; then
shift; arg="$1"
if [[ "$arg" != -Xlinker,* ]]; then
die "-Xlinker,-rpath was not followed by -Xlinker,*"
if [[ $arg != -Xlinker ]]; then
die "-Xlinker -rpath was not followed by -Xlinker <arg>"
fi
rpaths+=("${arg#-Xlinker,}")
shift; arg="$1"
rpaths+=("$arg")
else
other_args+=("-Xlinker,$arg")
other_args+=("-Xlinker")
other_args+=("$arg")
fi
;;
*)

View File

@@ -1 +0,0 @@
../../cc