You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tutorial_environments.rst
+11-40Lines changed: 11 additions & 40 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -76,6 +76,7 @@ Let's look at the output of ``spack find`` at this point in the tutorial.
76
76
77
77
This is a complete, but cluttered list of all our installed packages and their dependencies.
78
78
It contains packages built with both ``openmpi`` and ``mpich``, as well as multiple variants of other packages, like ``hdf5`` and ``zlib-ng``.
79
+
79
80
The query mechanism we learned about with ``spack find`` can help, but it would be nice if we could see only the software that is relevant to our current project instead of seeing everything on the machine.
80
81
81
82
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -155,6 +156,8 @@ Let's try it:
155
156
:language: console
156
157
157
158
Now, ``tcl`` and ``trilinos`` have been registered as **root specs** in our environment. **Root specs** are packages that we've explicitly requested to be installed in an environment.
159
+
160
+
158
161
They're called **"roots"** because they sit at the top of the dependency graph---when Spack installs these packages, with their respective dependency packages sitting below them.
159
162
160
163
Now, let's install:
@@ -173,38 +176,6 @@ Let's now confirm the contents of the environment using ``spack find``:
173
176
174
177
We can see that the roots and all their dependencies have been installed.
175
178
176
-
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
177
-
Creating an environment incrementally
178
-
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
179
-
180
-
We can also add and install specs to an environment incrementally. For example:
181
-
182
-
.. code-block:: console
183
-
184
-
$ spack install --add tcl
185
-
$ spack install --add trilinos
186
-
187
-
If we create environments incrementally, Spack ensures that already installed roots are not re-concretized.
188
-
So, adding specs to an environment at a later point in time will not cause existing packages to rebuild.
189
-
190
-
.. note::
191
-
192
-
Incrementally creating an environment may give us different package
193
-
versions from an environment created all at once.
194
-
We'll cover this later in the tutorial after we've discussed different
195
-
concretization strategies.
196
-
197
-
Further, there are two other advantages of concretizing and installing an
198
-
environment all at once:
199
-
200
-
201
-
* If you have a number of specs that can be installed together,
202
-
adding them first and installing them together enables them to
203
-
share dependencies and reduces total installation time.
204
-
205
-
* You can launch all builds in parallel by taking advantage of Spack's
@@ -305,15 +276,10 @@ In this section, we'll learn how to enforce that all the packages in our environ
305
276
306
277
We can customize the selection of the ``mpi`` provider using `concretization preferences <https://spack.readthedocs.io/en/latest/build_settings.html#concretization-preferences>`_ to change the behavior of the concretizer.
307
278
308
-
.. note::
309
279
310
-
Before proceeding, make sure your ``EDITOR`` environment variable
311
-
is set to the path of your preferred text editor.
312
-
313
-
Let's start by examining our environment's configuration using ``spack config edit``:
280
+
Let's start by examining our environment's configuration using ``spack config get``:
0 commit comments