This page summarizes the requirements to configure, build, and run mutable, and lists the dependencies of mutable.
Install the following tools:
- Git
- CMake (3.20 or newer)
- GNU Make / Ninja / some other build tool of your choice
- Clang 16 or newer (see Build Clang from Source)
- Doxygen (to generate the documentation)
- Perl (for our git-hooks)
- Pipenv (to set up a virtual Python environment and manage packages)
Further, if you wish to build mutable with its WebAssembly-based backend (which is the default), you need to install the following Google tools as well:
mutable depends on several third-parties. We ship most of them indirectly through CMake's "external projects". However, some third-parties are required to be installed on your system.
Below is a list of mandatory dependencies, that must be installed:
- Boost libraries and development header files.
- On ArchLinux:
pacman -S boost
- On ArchLinux:
- Graphviz development headers
- Make sure
gvc.h
is found in one your system include directories. - On ArchLinux:
pacman -S graphviz
- Make sure
The dependencies listed below are optional. Having them available on your system provides new features to mutable or improves working on mutable.
Doxygen can use Graphviz to render inheritance and collaboration diagrams.
- At least
graphviz>=1.8.10
is required by ourDoxyfile
. If you have an older version setDOT_MULTI_TARGETS = NO
. - On ArchLinux:
pacman -S graphviz
- On macOS:
brew install graphviz
.
We implement our own testing and benchmarking frameworks in Python. We manage our required packages with Pipenv and package versions are specified in the Pipfile.lock
file. Ensure that you have a Python provider installed, e.g. pyenv
or the currently required version of Python.
To install our required packages, run pipenv sync
.
See Building with V8.
We use perl
in our git-hooks. Make sure it is in your $PATH
.
We implement custom git-hooks to enforce code quality.
You must install them locally in your repo with the following commands:
$ cd .git/
$ rm -fr hooks/
$ ln -s ../hooks
This way, our hooks are properly installed and contained in version control.
- On macOS, setting up the Pipenv virtual environment can fail because of a build error in the
pygraphviz
setup. If the installation ofpygraphviz
withpipenv
fails with the following error:then the problem is that the required header file is not installed in one of the compiler's searched include directories. To resolve the problem, we must manually provide the include directory to the build offatal error: 'graphviz/cgraph.h' file not found
pygraphviz
.
- Run the following command to build
pygraphviz
with the additional include directory.$ pipenv run pip install --use-pep517 \ --config-settings="--global-option=build_ext" \ --config-settings="--global-option=-I$(brew --prefix graphviz)/include/" \ --config-settings="--global-option=-L$(brew --prefix graphviz)/lib/" \ pygraphviz
- Run
pipenv sync
as usual.
- On macOS, setting up the Pipenv virtual environment may fail while trying to install
psycopg2
with the following error.In this case, theError: pg_config executable not found
postgresql
binaries are not in thePATH
.
- Install a recent version of PostgreSQL, e.g.
postgresql@16
.$ brew install postgresql@16
- Add the binaries of your install PostgreSQL version, e.g.
postgresql@16
, to yourPATH
.$ export PATH="$PATH:$(brew --prefix postgresql@16)/bin"
- Run
pipenv sync
as usual.