Skip to content

Compiling on Debian Stretch (9.x)

Quentin Bazin edited this page Feb 14, 2020 · 7 revisions

Note: This page is outdated due to C++14 migration.

Since OpenMiner uses C++17, I highly recommend to upgrade to a supported system:

If you really want to use Debian Stretch (9.x), then I highly recommend to do this in a chroot or in a virtual machine, and not directly in your system.

Installing GameKit dependencies

sudo apt install libglm-dev libtinyxml2-dev libsdl2-dev libsdl2-image-dev libsdl2-mixer-dev libsdl2-ttf-dev

Compiling GameKit

git clone git://github.com/Quent42340/GameKit.git
cd GameKit
cmake . && make -j8
sudo make install

Installing OpenMiner dependencies

WARNING: This will copy files in /usr/include/ and could erase existing ones. These files won't be handled by package manager so be sure to keep track of them.

sudo apt install libsfml-dev liblua5.2-dev
sudo cp /usr/include/lua5.2/* /usr/include/

Installing a C++17 compliant compiler

WARNING: This will upgrade libstdc++6 to its latest version and enable testing repo, only do this if you're sure of what you're doing.

su -c "echo 'deb http://deb.debian.org/debian/ testing main' >> /etc/apt/sources.list"
sudo apt update
sudo apt install gcc-7 g++-7

Compiling OpenMiner

git clone git://github.com/Quent42340/OpenMiner.git
cd OpenMiner
CC=gcc-7 CXX=g++-7 cmake .
make -j8