diff options
author | Greg Becker <becker33@llnl.gov> | 2019-10-22 23:27:40 -0700 |
---|---|---|
committer | Todd Gamblin <tgamblin@llnl.gov> | 2019-10-22 23:27:40 -0700 |
commit | 95a48b27ec09b691d4107d48854126c045b03188 (patch) | |
tree | ba3285c667730336403f45a441b393758b9bf923 /.readthedocs.yml | |
parent | b14f18acda23c3299bea060b4d3424b8c72052a3 (diff) | |
download | spack-95a48b27ec09b691d4107d48854126c045b03188.tar.gz spack-95a48b27ec09b691d4107d48854126c045b03188.tar.bz2 spack-95a48b27ec09b691d4107d48854126c045b03188.tar.xz spack-95a48b27ec09b691d4107d48854126c045b03188.zip |
env activation: use package defined env setup methods (#13249)
This PR ensures that environment activation sets all environment variables set by the equivalent `module load` operations, except that the spec prefixes are "rebased" to the view associated with the environment.
Currently, Spack blindly adds paths relative to the environment view root to the user environment on activation. Issue #12731 points out ways in which this behavior is insufficient.
This PR changes that behavior to use the `setup_run_environment` logic for each package to augment the prefix inspections (as in Spack's modulefile generation logic) to ensure that all necessary variables are set to make use of the packages in the environment.
See #12731 for details on the previous problems in behavior.
This PR also updates the `ViewDescriptor` object in `spack.environment` to have a `__contains__` method. This allows for checks like `if spec in self.default_view`. The `__contains__` operator for `ViewDescriptor` objects checks whether the spec satisfies the filters of the View descriptor, not whether the spec is already linked into the underlying `FilesystemView` object.
Diffstat (limited to '.readthedocs.yml')
0 files changed, 0 insertions, 0 deletions