Building CompuCell3D on Linux

This writeup presents easy-to-follow instructions on how to build CC3D on Linux using CompuCell3D channel of Anaconda. Anaconda is a cloud-based system that provides easy-to-use cross-platform system for managing software packages and dependencies


On Ubuntu all items (except conda - it has to be installed manually) can be installed automatically using the following command:

sudo apt-get install g++ build-essential git libglu1-mesa libxi-dev libxmu-dev libglu1-mesa-dev

Important For this tutorial to work you need to make sure that is in the /usr/lib64. On Ubuntu this library will be installed in /usr/lib/x86_64-linux-gnu In this case you may have to create symbolic link (you have to be sudo to do that)

ln -s /usr/lib/x86_64-linux-gnu /usr/lib64

If you are on CentOS 7.x or RedHat 7.x you may have more work to do but it is fairly straightforward because you will need to create more symbolic links for completeness we are listing the commands necessary to accomplish this task:

cd /usr/lib64

ln -s
ln -s
ln -s
ln -s
ln -s
ln -s
ln -s

Of course you need to do it as super user and keep in mind that the library numbers (.so.x) may vary depending on your system version

Important: You may need to apply additionial fix apply on newer linuxes (Ununtu 18.04 RedHat 7.5) Thi sis related to the issue of that shows up during the compilation and is related to SWIG complaining that it is unable find "swig.swg" file (and few others). The temporary solution is to uninstall system swig and install swig from source by following download links from


Get main cc3d repository by running from your home directory the following command

mkdir ~/CC3D_GIT

cd ~/CC3D_GIT

git clone .

Get cc3d_build_scripts repository by running from your home directory the following command

git clone

Once the cloning process is complete go to the directory where the script for the current version of cc3d is located:

cd cc3d_build_scripts/linux/376

To run the build/install script run the following command:

python --prefix=~/cc3d_376 --source-root=~/CC3D_GIT --build-dir=~/cc3d_376_build --version=3.7.6 --cores=2 --conda-env-name=cc3d_python

After last command completes few things will happen:

  1. new conda environment (cc3d_python) will be created ( script will do this automatically for you)

  2. the dependencies needed to build CC3D will be downloaded
  3. CC3D will be installed will be installed in ~/cc3d_376 . Temporary compilation files will get stored in ~/cc3d_376_build

Now all you have to do is to go the the installation directory and run CC3D:

cd ~/cc3d_376


CompuCell3D: SrcBin/CompilingOnLinux2017 (last edited 2018-09-12 02:59:38 by mswat)