Let packages call use_cray_compilers() in install to get , etc set to cray names

This commit is contained in:
Gregory Becker 2016-07-18 15:43:21 -07:00
parent 46ee4a3a53
commit 218fc602fa
5 changed files with 12 additions and 2 deletions

4
lib/spack/env/cc vendored
View File

@ -110,13 +110,13 @@ case "$command" in
comp="CXX"
lang_flags=CXX
;;
f90|fc|f95|gfortran|ifort|pgfortran|xlf90|nagfor)
ftn|f90|fc|f95|gfortran|ifort|pgfortran|xlf90|nagfor)
command="$SPACK_FC"
language="Fortran 90"
comp="FC"
lang_flags=F
;;
f77|gfortran|ifort|pgfortran|xlf|nagfor)
f77|gfortran|ifort|pgfortran|xlf|nagfor|ftn)
command="$SPACK_F77"
language="Fortran 77"
comp="F77"

1
lib/spack/env/craype/CC vendored Symbolic link
View File

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

1
lib/spack/env/craype/cc vendored Symbolic link
View File

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

1
lib/spack/env/craype/ftn vendored Symbolic link
View File

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

View File

@ -1439,6 +1439,13 @@ def install_dependency_symlinks(pkg, spec, prefix):
flatten_dependencies(spec, prefix)
def use_cray_compiler_names():
"""Compiler names for builds that rely on cray compiler names."""
os.environ['CC'] = 'cc'
os.environ['CXX'] = 'CC'
os.environ['FC'] = 'ftn'
os.environ['F77'] = 'ftn'
def flatten_dependencies(spec, flat_dir):
"""Make each dependency of spec present in dir via symlink."""
for dep in spec.traverse(root=False):