Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 28 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,36 @@ An alternative would be the [NixOS](https://nixos.org/).
### Prerequisites

The bootstrap process will need a clean environment with a compiler (the system version of gcc will do). It also is very sensitive to
the environment, so setup a user with unset CFFLAGS, CFLAGS, LDFLAGS, PKG_CONFIG_PATH and the always harmful LD_LIBRARY_PATH variables.
EESSI provides a singularity container for this.
the environment, so setup a user with unset `CFFLAGS`, `CFLAGS`, `LDFLAGS`, `PKG_CONFIG_PATH` and the always harmful `LD_LIBRARY_PATH` variables.

EESSI provides a Singularity container for this.

### Building the Singularity container
The provided Singularity definition file can be used to build a container with a clean environment:
```
sudo singularity build bootstrap-prefix.sif singularity-bootstrap-prefix.def
```

### Bootstrapping Gentoo Prefix
Gentoo Prefix provides a bootstrap script to build the prefix. See [Gentoo Prefix Bootstrap](https://wiki.gentoo.org/wiki/Project:Prefix/Bootstrap)
or build and use the singularity container. After starting the bootstrap have a long coffee...
Gentoo Prefix provides a bootstrap script to build the prefix, see [Gentoo Prefix Bootstrap](https://wiki.gentoo.org/wiki/Project:Prefix/Bootstrap).
We forked [this version](https://gitweb.gentoo.org/repo/proj/prefix.git/tree/scripts/bootstrap-prefix.sh?id=e77fd01734f21ec2e9c985c28ba4eb30c1b2bc9d)
and made some modifications. See issue [#8](https://github.com/EESSI/compatibility-layer/issues/8) for more details.

You can run our version of the bootstrap script (see `bootstrap-prefix.sh`) inside the Singularity container by executing:
```
singularity run bootstrap-prefix.sif
```
or simply:
```
./bootstrap-prefix.sif
```

If you want to run your own version of the bootstrap script, use:
```
singularity exec bootstrap-prefix.sif ./bootstrap-prefix.sh
```

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The installation path can also be set in the environment as $EPREFIX

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Haven't tried this myself (does that also skip the other questions about wishing the script luck?), but added a note about it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It does not skip the questions, but saves time typing

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And it avoids accidentally installing to a different location... :)

+1 for defining $EPREFIX up front

I also had to do this, because some /etc/profile.d scripts in the system I'm playing on define $LD_LIBRARY_PATH & co:

export SHELL="/bin/bash --norc --noprofile

The Prefix bootstrap script gives up when it sees things like $LD_LIBRARY_PATH and $CPATH defined in a freshly created shell.

After starting the bootstrap have a long coffee...

### Adding EESSI overlay
Additional packages are added in the EESSI overlay, which is based on ComputeCanada.
Expand All @@ -36,5 +60,3 @@ Sync the overlay
```
emerge --sync
```


Loading