Steps to install and build SOFA with soft robots from scratch on a fresh Ubuntu 18.04 virtual machine (windows host)
Naturally we start with update and installing git
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install git
From linux build instructions here
sudo apt-get install build-essential cmake cmake-qt-gui
sudo apt-get install ccache
Boost
sudo apt-get install libboost-atomic-dev libboost-chrono-dev libboost-date-time-dev libboost-filesystem-dev libboost-locale-dev libboost-regex-dev libboost-system-dev libboost-thread-dev libboost-program-options-dev
Python
sudo apt-get install python2.7-dev python-numpy python-scipy
Other libraries
sudo apt-get install libpng-dev libjpeg-dev libtiff-dev zlib1g-dev libglew-dev
sudo apt-get install libxml2-dev libcgal-dev libblas-dev liblapack-dev libsuitesparse-dev libassimp-dev
QT - unified installer - downloaded file qt-unified-linux-x64-3.1.1-online.run
and make it executable
chmod a+x qt-unified-linux-x64-3.1.1-online.run
./qt-unified-linux-x64-3.1.1-online.run
Do not create an account. Under the latest version
- check
Desktop gcc 64-bit
and qt charts
Now we are following the soft robots build instructions instead here
from home get latest unstable sofa
git clone -b master https://github.com/sofa-framework/sofa.git sofa/master/src/
this makes /home/james/sofa/master/src
from home again
git clone https://github.com/SofaDefrost/SoftRobots
git clone https://github.com/SofaDefrost/STLIB.git
cd to /home/james/sofa
then run the cmake gui cmake-gui
-
point source to
/home/james/sofa/master/src
-
point build directory to
/home/james/sofa/build
-
Click
generate
and then use defaults "unix makefiles" and "use default native compilers" -
add
/home/james/STLIB;/home/james/SoftRobots;
toSOFA_EXTERNAL_DIRECTORIES
THE ORDER MATTERS -
check
PLUGIN_SOFAPYTHON
-
check
SOFA_BUILD_METIS
-
check
SOFA_USE_CCACHE
-
check
SOFA_BUILD_TUTORIALS
If you hit generate then we get errors because it cannot find qt, so use the instructions at the bottom here
- click Add Entry then
CMAKE_PREFIX_PATH
with type path and then point to path/home/james/Qt/5.13.0/gcc_64
If you configure now you should get "Configuring done"
Hit Generate, and then in the build directory
make -j 4