Installing Chaste using the Ubuntu package
For Ubuntu users, there is a package available to greatly ease installation of the Chaste source code. It requires an Ubuntu version of Intrepid or newer, as several dependencies are not available as Ubuntu packages in older versions. We have also had success installing Chaste on a virtual machine running Ubuntu in other versions of Linux, Mac OS X and Windows.
The package has been tested with all versions of Ubuntu from Intrepid (8.10) to Focal (20.04) inclusive, and will be adapted to new versions as soon as possible after they are released.
Each release of Chaste should work with all supported versions of Ubuntu at the time of the Chaste release. But note that the latest Chaste releases won't work with the oldest (unsupported) Ubuntus, and the older Chaste releases (and their associated bolt-on projects) probably won't work with the newest Ubuntus without some updating (to use newer dependencies and compilers). The development code should always work with all the currently supported versions of Ubuntu.
1. Accessing the Chaste Package
The package can be downloaded using your normal package manager (e.g. aptitude) by adding our repository to your configuration. This can be done by, for example, opening a terminal and running
sudo nano /etc/apt/sources.list.d/chaste.list
and, depending on your version of Ubuntu, add one of the following lines to the chaste.list text file:
Ubuntu Version | Ubuntu codename | Line to add |
13.10 or older | - | deb http://www.cs.ox.ac.uk/chaste/ubuntu legacy/ |
14.04 LTS | trusty | deb http://www.cs.ox.ac.uk/chaste/ubuntu trusty/ |
14.10 | utopic | deb http://www.cs.ox.ac.uk/chaste/ubuntu utopic/ |
15.04 | vivid | deb http://www.cs.ox.ac.uk/chaste/ubuntu vivid/ |
15.10 | wily | deb http://www.cs.ox.ac.uk/chaste/ubuntu wily/ |
16.04 LTS | xenial | deb http://www.cs.ox.ac.uk/chaste/ubuntu xenial/ |
16.10 | yakkety | deb http://www.cs.ox.ac.uk/chaste/ubuntu yakkety/ |
17.04 | zesty | deb http://www.cs.ox.ac.uk/chaste/ubuntu zesty/ |
17.10 | artful | deb http://www.cs.ox.ac.uk/chaste/ubuntu artful/ |
18.04 LTS | bionic | deb http://www.cs.ox.ac.uk/chaste/ubuntu bionic/ |
18.10 | cosmic | deb http://www.cs.ox.ac.uk/chaste/ubuntu cosmic/ |
19.04 | disco | deb http://www.cs.ox.ac.uk/chaste/ubuntu disco/ |
19.10 | eoan | deb http://www.cs.ox.ac.uk/chaste/ubuntu eoan/ |
20.04 LTS | focal | deb http://www.cs.ox.ac.uk/chaste/ubuntu focal/ |
The last component of the line depends on your version of Ubuntu, as listed at https://wiki.ubuntu.com/DevelopmentCodeNames. Type lsb_release -a to find this out if you don't already know it. Note that the trailing "/" is necessary!
Next, install the Chaste public licence key. Back in the terminal, type:
sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 422C4D99
Note that you also need to ensure you have enabled 'multiverse' packages; this is normally the default.
2. Getting the correct dependencies
After following point 1 above, you should be able to install the dependencies for Chaste by running:
sudo apt-get update sudo apt-get install chaste-dependencies
You should now decide whether you want to be a Code User or a Code Developer.
- Code Users - are people who want to work with a stable released version of the Chaste code (a new release is made roughly every six months).
- Code Developers - (both internal and external to the core team) are people who want to work with the latest development version of the Chaste code, between the main stable releases.
See GettingStarted for more detail if you still aren't sure.
2a. For Code USERS (working with a release, rather than developers)
You can obtain the latest stable release of the Chaste source code from our GitHub repository:
git clone --recursive -b release https://chaste.cs.ox.ac.uk/git/chaste.git Chaste
Finally, follow the CMake First Run guide to get up and running with Chaste.
Installing previous releases
If you want a specific version of Chaste, and do not want to stay up-to-date with new versions on the release branch from our Git repository, you can download the source code from our GitHub releases page, back to Release 3.0.
2b. For Code DEVELOPERS (or users working with the latest trunk code and projects)
To install the suggested packages:
# first, make aptitude aware of the latest changes sudo apt-get update # then install sudo apt-get install --install-recommends chaste-dependencies sudo apt-get install `dpkg -s chaste-dependencies | egrep "^Suggests" | cut -d "," -f 1-111 --output-delimiter " " | cut -d ":" -f 2`
If you want to use eclipse to work with Chaste (as we do - recommended), after the above you will then need to:
- clone the Chaste repository.
- SetupEclipse - update eclipse settings to use Chaste code formatting etc.
If you don't want to use eclipse you can checkout at the command line. You can get information on the latest stable build on the external developer guide page.
If you have the necessary permissions, see also Check out a user project - to make a new user project, or get a copy of an existing one.
Manual adjustments
You can choose different blas/lapack implementations. Look particularly at the atlas packages, (apt-cache search libatlas to see the options). Use libatlas-sse2-dev on Intel, libatlas-3dnow-dev on AMD, libatlas-base-dev otherwise.
3. Possible issues
Errors after tests
Some of the older versions of Ubuntu (oneiric/precise) come with Boost 1.46.1, which unfortunately contains a bug (fixed in quantal / boost 1.48).
This bug leads to output like this, at the end of a test:
Running 4 tests ***** TestCell.hpp ***** Entering TestUpdateCellProliferativeTypes Passed Entering TestWithWntCellCycleModel Passed Entering TestWithStochasticWntCellCycleModel Passed Entering TestWntMutantVariantsAndLabelling Passed OK! pure virtual method called terminate called without an active exception [csu7921:16267] *** Process received signal *** [csu7921:16267] Signal: Aborted (6) [csu7921:16267] Signal code: (-6) [csu7921:16267] [ 0] /lib/x86_64-linux-gnu/libpthread.so.0(+0xfcb0) [0x7f4f75a2ecb0] [csu7921:16267] [ 1] /lib/x86_64-linux-gnu/libc.so.6(gsignal+0x35) [0x7f4f75698445] [csu7921:16267] [ 2] /lib/x86_64-linux-gnu/libc.so.6(abort+0x17b) [0x7f4f7569bbab] [csu7921:16267] [ 3] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(_ZN9__gnu_cxx27__verbose_terminate_handlerEv+0x11d) [0x7f4f7620369d] [csu7921:16267] [ 4] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0xb5846) [0x7f4f76201846] [csu7921:16267] [ 5] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0xb5873) [0x7f4f76201873] [csu7921:16267] [ 6] /usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0xb628f) [0x7f4f7620228f] [csu7921:16267] [ 7] /usr/lib/libboost_serialization.so.1.46.1(_ZNK5boost13serialization16void_cast_detail11void_casterltERKS2_+0x26) [0x7f4f79df7466] [csu7921:16267] [ 8] /usr/lib/libboost_serialization.so.1.46.1(_ZNK5boost13serialization16void_cast_detail11void_caster20recursive_unregisterEv+0x9a) [0x7f4f79df755a] [csu7921:16267] [ 9] /home/wolf1768/workspace/Chaste/lib/libpde.so(_ZN5boost13serialization16void_cast_detail21void_caster_primitiveI22ConstBoundaryConditionILj1EE25AbstractBoundaryConditionILj1EEED1Ev+0x2b) [0x7f4f7db419dd] [csu7921:16267] [10] /home/wolf1768/workspace/Chaste/lib/libpde.so(_ZN5boost13serialization6detail17singleton_wrapperINS0_16void_cast_detail21void_caster_primitiveI22ConstBoundaryConditionILj1EE25AbstractBoundaryConditionILj1EEEEED1Ev+0x34) [0x7f4f7db41a80] [csu7921:16267] [11] /lib/x86_64-linux-gnu/libc.so.6(__cxa_finalize+0x9d) [0x7f4f7569dd3d] [csu7921:16267] [12] /home/wolf1768/workspace/Chaste/lib/libpde.so(+0x1992d6) [0x7f4f7daac2d6] [csu7921:16267] *** End of error message *** Aborted (core dumped)
Fortunately this doesn't affect the running of the tests, which execute normally, but just display errors on shutdown. As long as you see "OK!", everything is OK!
If you do see this in tests, then when running a compiled executable you may see this at the end:
terminate called after throwing an instance of 'Exception' Aborted
this is not a problem either, and executable should have run correctly.
If this really does offend you (it can be very annoying if you are doing development and/or memory testing), then precise (12.04 LTS) also makes boost 1.48 available which doesn't have this bug. Unfortunately this isn't the default and you have to install it manually. (NB: These instructions are for the release 3.1 package; with the latest beta you should be able to do just "sudo apt-get install libboost-serialization1.48-dev libboost-filesystem1.48-dev".)
- Remove the existing chaste-dependencies which the system thinks relies on boost 1.46.
sudo apt-get remove chaste-dependencies
- List all the chaste dependencies with a command like this:
apt-cache show chaste-dependencies | head -30
- Copy the names of the ones you want
- Replace libboost-serialization-dev and libboost-filesystem-dev with libboost-serialization1.48-dev and libboost-filesystem1.48-dev,
- Install them all (this can be done in multiple calls) with:
sudo apt-get install <list of packages>
Old versions of Chaste
For release 2.0 of Chaste and earlier, note that 4 tests (TestQuadraticMesh, TestVoronoiTessellation, TestVertexMesh, and TestInventorVoronoiWriter) may be reported as failing. This is due to a different version of tetgen being used in Ubuntu. Release 2.1 packages tetgen in the Chaste distribution and so avoids the problem.
If working with older versions, installing tetgen 1.4.2 manually as described at InstallTetgenAndTetview (and ensuring that this version appears on your PATH before the system version) resolves the problems.