Skip to content

Compiling on Ubuntu 20.04 gcc 9 x86_64 using Ubuntu package system

Steven A White edited this page Jun 2, 2022 · 1 revision

These instructions depend on the following packages

packages

  1. wget
  2. build-essential
  3. g++
  4. git
  5. ninja-build
  6. libncurses5-dev
  7. libeigen3-dev
  8. libxerces-c-dev
  sudo apt-get install wget
  sudo apt-get install git
  sudo apt-get install ninja-build
  sudo apt-get install libncurses5-dev
  sudo apt-get install build-essential
  sudo apt-get install g++
  sudo apt-get install automake
  sudo apt-get install libeigen3-dev
  sudo apt-get install libxerces-c-dev

Installing CMake

If you do not want to install CMake 3.16 as a global package remember to update your PATH variable to include the installation directory you choose.

cd ~
mkdir src
cd src
wget https://github.com/Kitware/CMake/releases/download/v3.16.5/cmake-3.16.5.tar.gz
tar -xf cmake-3.16.*.tar.gz
cd cmake-3.16.5
./bootstrap --parallel=4 --prefix=/usr/local
make -j4
sudo make install

installing eigen

sudo apt-get install libeigen3-dev

installing xerces-c

sudo apt-get install libxerces-c-dev

installing xsd

wget https://www.codesynthesis.com/download/xsd/4.0/linux-gnu/x86_64/xsd_4.0.0-1_amd64.deb
sudo dpkg -i xsd_4.0.0-1_amd64.deb

installing SSL

sudo apt-get install libssl-dev

Note that this step can be avoided if you instead uncheck the CMake setting MZ_OPENSSL.

Building Biogears Core

cd /opt/biogears/
git clone https://github.com/BioGearsEngine/core.git core
cd core
mkdir build; cd build
cmake -G "Ninja" -DCMAKE_BUILD_TYPE=Release \
                 -DCMAKE_INSTALL_PREFIX=/opt/biogears/usr \
                 -DBiogears_BUILD_JAVATOOLS=OFF \
                 ..

ninja bg-cli