Commit b6579918 authored by Rob Latham's avatar Rob Latham
Browse files

improve documentation

Matthieu correctly points out the documentation was a little sparse.
Add information about what one does after installing the repo: kind of a
spack crash course.
parent a474cecd
......@@ -7,7 +7,7 @@ For more about spack and what you can do with it, spack has lots of
[documentation](https://spack.readthedocs.io/en/latest/) and a good
[tutorial](https://spack.readthedocs.io/en/latest/tutorial_sc16.html).
## Installation
## Repo Installation
Once you've set up spack itself, you need to teach it about this collection
('repository' in spack lingo) of pacakges. Go to the top-level directory of
......@@ -18,3 +18,75 @@ this project and execute the following command:
Did it work?
spack repo list
## Mochi Suite Installation
To build the entire mochi suite with the default configuration (mercury using
CCI's TCP transport), simply build margo:
spack install margo
### System boost vs. spack boost
The largest dependency for Mercury is the Boost package. If your system
already has Boost, you can teach spack about it and other
[system packages](https://spack.readthedocs.io/en/latest/getting_started.html#system-packages).
Let's say you installed Boost through your distribution (an RPM or DEB package)
To inform spack about Boost you e.g. installed from an RPM, you would add it to
`~/.spack/packages.yaml`
```
packages:
boost:
paths:
boost@system: /usr
version: [system]
buildable: False
```
## Using Mochi Suite
One consequence of the spack design (where packages are installed into a prefix
based on a hash of their configuration and compiler) is that library and header
paths are unwieldy. An environment-managment tool such as `moudles` helps a
lot here, and is nicely integrated into spack:
```
module avail
--- /blues/gpfs/home/robl/src/spack/share/spack/modules/linux-centos6-x86_64 ---
abtsnoozer-master-gcc-4.7.2-4ygmjep libev-4.24-gcc-4.7.2-ddpazlc
argobots-master-gcc-4.7.2-4wxy6p3 libsigsegv-2.10-gcc-4.7.2-vtvikjs
autoconf-2.69-gcc-4.7.2-a2clqmr libtool-2.4.6-gcc-4.7.2-nxthahu
automake-1.15-gcc-4.7.2-bfjmuzz m4-1.4.18-gcc-4.7.2-hftmdfw
boost-1.63.0-gcc-4.7.2-ds3fbl3 margo-master-gcc-4.7.2-uy4in2w
bzip2-1.0.6-gcc-4.7.2-jehobzs mercury-master-gcc-4.7.2-eiyjtqs
cci-2.0-gcc-4.7.2-5y6vgzq zlib-1.2.10-gcc-4.7.2-w53w2nl
...
```
Load the margo module into your environment:
module add margo-master-gcc-4.7.2-uy4in2w
The dependency resolution does not appear to be automatic (perhaps RobL needs
to adjust or declare runtime depenencies?), so you'll have to
add mercury, argobots, and abt-snoozer by hand as well.
```
module list
Currently Loaded Modulefiles:
1) margo-master-gcc-4.7.2-uy4in2w
2) mercury-master-gcc-4.7.2-eiyjtqs
3) abtsnoozer-master-gcc-4.7.2-4ygmjep
4) argobots-master-gcc-4.7.2-4wxy6p3
```
The modules framework will update the `PKG_CONFIG_PATH` for you:
```
pkg-config --cflags margo
-I/blues/gpfs/home/robl/src/spack/opt/spack/linux-centos6-x86_64/gcc-4.7.2/argobots-master-4wxy6p3thpyhwgo67t6icducpy3ik6y5/include -I/blues/gpfs/home/robl/src/spack/opt/spack/linux-centos6-x86_64/gcc-4.7.2/abtsnoozer-master-4ygmjeptxkfddgojrupre624olf2w6mq/include -I/blues/gpfs/home/robl/src/spack/opt/spack/linux-centos6-x86_64/gcc-4.7.2/mercury-master-eiyjtqsdv6yynaylgtm5g7jib7fvnshh/include -I/blues/gpfs/home/robl/src/spack/opt/spack/linux-centos6-x86_64/gcc-4.7.2/boost-1.63.0-ds3fbl3vdsk6u5soirxcdoe3e6dw3iwx/include -I/blues/gpfs/home/robl/src/spack/opt/spack/linux-centos6-x86_64/gcc-4.7.2/cci-2.0-5y6vgzqccmk7n7vehrrcxl5ogukwv3gh/include -I/blues/gpfs/home/robl/src/spack/opt/spack/linux-centos6-x86_64/gcc-4.7.2/margo-master-uy4in2w6xniwn43iio7h6ko3j6hbxvfr/include
```
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment