Tomatenquark relies on the excellent vcpkg package management. In order to get started you will need the following ingredients.
gitcmake
You will need a recent version of Visual Studio alongside the C/C++ extension pack.
In order for compilation to work you must have the following packages available:
libgllibvorbisalsa
On Ubuntu you can get these dependencies via:
sudo apt-get install -y libgl1-mesa-dev libasound2-dev libvorbis-dev
On OSX we recommend using XCode. However, tomatenquark may be built using plain Makefile.
In order to build the project follow these steps:
- clone
vcpkginto a location of your choosing and set it up. - clone
codeinto a location of your choosing - installing the necessary dependencies
- platform-dependant compilation
Navigate to your vcpkg directory and install a triplet of your choosing:
./vcpkg install --recurse @/path/to/code/cmake/triplets/linux64
#.\vcpkg install --recurse @/path/to/code/cmake/triplets/windows64 # on windows
cd \path\to\code
mkdir build && cd build
cmake .. -DCMAKE_TOOLCHAIN_FILE=\path\to\vcpkg\scripts\buildsystems\vcpkg.cmake
msbuild /property:Platform=x64 /t:tomatenquark tomatenquark.sln
cd /path/to/code
mkdir build && cd build
cmake .. -DCMAKE_TOOLCHAIN_FILE=/path/to/vcpkg/scripts/buildsystems/vcpkg.cmake -G Xcode
xcodebuild -arch x86_64 build
If you prefer Makefiles over project files, head straight to the linux section.
cd /path/to/code
mkdir build && cd build
cmake .. -DCMAKE_TOOLCHAIN_FILE=/path/to/vcpkg/scripts/buildsystems/vcpkg.cmake
make tomatenquark
The server only version works with fewer dependencies. You will need only to install enet and zlib.
When building the code select the tomaten_server or tomaten_master target, e.g:
.\vcpkg install enet zlib --triplet x64-linux
# (cd to code)
mkdir build && cd build
cmake .. -DCMAKE_TOOLCHAIN_FILE=/path/to/vcpkg/scripts/buildsystems/vcpkg.cmake
make tomaten_server