summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTodd Gamblin <tgamblin@llnl.gov>2015-03-13 13:32:24 -0700
committerTodd Gamblin <tgamblin@llnl.gov>2015-03-13 13:32:24 -0700
commit32244ac733f6276e50511e42620b49be90f72f0b (patch)
tree64d4b74bc5ac6f02a31e5398041c45d1c464920a
parentb80e091f46ca7559b4b81922d9af33fb8fe1d4d5 (diff)
downloadspack-32244ac733f6276e50511e42620b49be90f72f0b.tar.gz
spack-32244ac733f6276e50511e42620b49be90f72f0b.tar.bz2
spack-32244ac733f6276e50511e42620b49be90f72f0b.tar.xz
spack-32244ac733f6276e50511e42620b49be90f72f0b.zip
MPICH provides environment vars to make MPI compilers behave like spack.
-rw-r--r--var/spack/packages/mpich/package.py9
-rw-r--r--var/spack/packages/scotch/package.py1
2 files changed, 10 insertions, 0 deletions
diff --git a/var/spack/packages/mpich/package.py b/var/spack/packages/mpich/package.py
index 57378626ab..6aa8f2eca4 100644
--- a/var/spack/packages/mpich/package.py
+++ b/var/spack/packages/mpich/package.py
@@ -38,6 +38,15 @@ class Mpich(Package):
provides('mpi@:3', when='@3:')
provides('mpi@:1', when='@1:')
+
+ def setup_dependent_environment(self, module, spec, dep_spec):
+ """For dependencies, make mpicc's use spack wrapper."""
+ os.environ['MPICH_CC'] = 'cc'
+ os.environ['MPICH_CXX'] = 'c++'
+ os.environ['MPICH_F77'] = 'f77'
+ os.environ['MPICH_F90'] = 'f90'
+
+
def install(self, spec, prefix):
config_args = ["--prefix=" + prefix,
"--enable-shared"]
diff --git a/var/spack/packages/scotch/package.py b/var/spack/packages/scotch/package.py
index 502d79f076..79289ff2ad 100644
--- a/var/spack/packages/scotch/package.py
+++ b/var/spack/packages/scotch/package.py
@@ -10,6 +10,7 @@ class Scotch(Package):
list_url = "http://gforge.inria.fr/frs/?group_id=248"
version('6.0.3', '10b0cc0f184de2de99859eafaca83cfc')
+
depends_on('mpi')