summaryrefslogtreecommitdiff
path: root/lib/spack/docs/packaging_guide.rst
diff options
context:
space:
mode:
authorTodd Gamblin <tgamblin@llnl.gov>2015-02-23 01:22:49 -0800
committerTodd Gamblin <tgamblin@llnl.gov>2015-02-23 01:23:30 -0800
commit5699cbb597468911c0b34988512ddea8b4c62ecc (patch)
treec2a7d57320fafe5bc413b182a83f914cf4c84523 /lib/spack/docs/packaging_guide.rst
parent6dab133d9f001d5e03fde25bdd3d412adf2a7b56 (diff)
downloadspack-5699cbb597468911c0b34988512ddea8b4c62ecc.tar.gz
spack-5699cbb597468911c0b34988512ddea8b4c62ecc.tar.bz2
spack-5699cbb597468911c0b34988512ddea8b4c62ecc.tar.xz
spack-5699cbb597468911c0b34988512ddea8b4c62ecc.zip
Fix SPACK-60: 0.8.15 basic docs.
Diffstat (limited to 'lib/spack/docs/packaging_guide.rst')
-rw-r--r--lib/spack/docs/packaging_guide.rst74
1 files changed, 74 insertions, 0 deletions
diff --git a/lib/spack/docs/packaging_guide.rst b/lib/spack/docs/packaging_guide.rst
index ec2ca4d099..e5ebdb4cd2 100644
--- a/lib/spack/docs/packaging_guide.rst
+++ b/lib/spack/docs/packaging_guide.rst
@@ -2032,6 +2032,80 @@ to get rid of the install prefix before you build again:
spack uninstall -f <spec>
+Graphing Dependencies
+--------------------------
+
+Spack provides the ``spack graph`` command for graphing dependencies.
+The command by default generates an ASCII rendering of a spec's
+dependency graph. For example::
+
+ $ spack graph mpileaks
+ o mpileaks
+ |\
+ | |\
+ | o | callpath
+ |/| |
+ | |\|
+ | |\ \
+ | | |\ \
+ | | | | o adept-utils
+ | |_|_|/|
+ |/| | | |
+ o | | | | mpi
+ / / / /
+ | | o | dyninst
+ | |/| |
+ |/|/| |
+ | | |/
+ | o | libdwarf
+ |/ /
+ o | libelf
+ /
+ o boost
+
+At the top is the root package in the DAG, with dependency edges
+emerging from it. On a color terminal, the edges are colored by which
+dependency they lead to.
+
+You can also use ``spack graph`` to generate graphs in the widely used
+`Dot <http://www.graphviz.org/doc/info/lang.html>`_ format. For
+example::
+
+ $ spack graph --dot mpileaks
+ digraph G {
+ label = "Spack Dependencies"
+ labelloc = "b"
+ rankdir = "LR"
+ ranksep = "5"
+
+ "boost" [label="boost"]
+ "callpath" [label="callpath"]
+ "libdwarf" [label="libdwarf"]
+ "mpileaks" [label="mpileaks"]
+ "mpi" [label="mpi"]
+ "adept-utils" [label="adept-utils"]
+ "dyninst" [label="dyninst"]
+ "libelf" [label="libelf"]
+
+ "callpath" -> "dyninst"
+ "callpath" -> "adept-utils"
+ "callpath" -> "mpi"
+ "callpath" -> "libelf"
+ "callpath" -> "libdwarf"
+ "libdwarf" -> "libelf"
+ "mpileaks" -> "adept-utils"
+ "mpileaks" -> "callpath"
+ "mpileaks" -> "mpi"
+ "adept-utils" -> "boost"
+ "adept-utils" -> "mpi"
+ "dyninst" -> "boost"
+ "dyninst" -> "libelf"
+ "dyninst" -> "libdwarf"
+ }
+
+This graph can be provided as input to other graphing tools, such as
+those in `Graphviz <http://www.graphviz.org>`_.
+
Interactive Shell Support
--------------------------