Building Arcadia
Arcadia is built with Kitware CMake and requires CMake 3.29 or better. The instructions below perform an out-of-source build: no build file, intermediate file, or product file is written into the source directory, everything lands in a dedicated build directory outside of it. Arcadia rejects in-source builds.
Getting the sources
Check out the Arcadia GitHub repository into a directory in your file system. This manual calls that directory the source directory.
git clone https://github.com/michaelheilmann/arcadia
Create a second directory outside of the source directory to build in, for example as a sibling of the source directory. This manual calls that directory the build directory.
Windows 11 and Visual Studio Community 2022
Building under Windows requires
- Microsoft Visual Studio Community 2022 version 17.9.2 or better, available at visualstudio.microsoft.com/vs/community.
- Kitware CMake version 3.29 or better, available at cmake.org.
- PowerShell or Command Prompt.
The file CMakePresets.json in the source directory provides configure presets for the target
architectures x64 and Win32. Run the following commands from the build directory.
Substitute <source-directory> and <build-directory> with your own paths.
cmake -S <source-directory> -B <build-directory>/x64 --preset x64
cmake -S <source-directory> -B <build-directory>/Win32 --preset Win32
The solution file Arcadia.sln is generated in the preset build directory.
Arcadia depends on external libraries — a C/C++ runtime, libpng, and others. They are not
part of the repository. They are downloaded as a prebuilt archive from the releases of the
Arcadia dependencies repository. The CMake target
Arcadia.InstallDependencies performs that download for you. Run it once per build directory, after
the first configure step:
cmake --build <build-directory>/x64 --target "Arcadia.InstallDependencies"
Building the whole solution is then a matter of picking a configuration:
cmake --build <build-directory>/x64 --config Debug
cmake --build <build-directory>/x64 --config Release
cmake --build <build-directory>/x64 --config MinSizeRel
cmake --build <build-directory>/x64 --config RelWithDebInfo
Alternatively, build a single target by appending --target <target>, or open
<build-directory>/x64/Arcadia.sln in Visual Studio and build from there.
Linux
Building under Linux requires
- make version 4.3.0 or better —
sudo apt-get install build-essential - gcc version 11.4.0 or better —
sudo apt-get install gcc - cmake version 3.29 or better —
sudo apt-get install cmake - libpng version 1.6 or better —
sudo apt-get install libpng-dev - optional: gdb version 12.1 or better —
sudo apt-get install gdb
The engine backends are disabled by default. Install their development packages and enable the ones you want:
- X11 display/windowing —
sudo apt-get install libx11-dev libxrandr-dev - OpenGL 4 via GLX —
sudo apt-get install libglx-dev - OpenAL audials —
sudo apt-get install libopenal-dev - FLAC decoding —
sudo apt-get install libflac-dev
Configure and build from the build directory. The build type defaults to a release build without debug
information; add -DCMAKE_BUILD_TYPE="Debug" for a debug build.
cmake -S <source-directory> -B <build-directory> -D"Arcadia.Engine.Visuals.Implementation.OpenGL4.Enabled"=TRUE -D"Arcadia.Engine.Audials.Implementation.OpenAL.Enabled"=TRUE
make -C <build-directory> all
Configuration options
The engine backends are controlled by CMake options. All of them default to FALSE.
Arcadia.Engine.Visuals.Implementation.OpenGL4.Enabled |
OpenGL 4 support in Arcadia Engine Visuals, through GLX on Linux and WGL on Windows. |
Arcadia.Engine.Visuals.Implementation.Direct3D12.Enabled |
Direct3D 12 support in Arcadia Engine Visuals. Windows only. |
Arcadia.Engine.Visuals.Implementation.Vulkan.Enabled |
Vulkan support in Arcadia Engine Visuals. Windows only. |
Arcadia.Engine.Audials.Implementation.OpenAL.Enabled |
OpenAL support in Arcadia Engine Audials. |
Testing
Test modules are registered with CTest. Run them from the build directory. For a multi-configuration generator such as Visual Studio, pass the configuration you built:
ctest --test-dir <build-directory>/x64 -C Debug
ctest --test-dir <build-directory>/x64 -C Debug -R Arcadia.Ring2.Tests.StringTests
License
Arcadia is free software, licensed under the
GNU Affero General Public License, version 3, or (at
your option) any later version. The full license text is distributed with the repository in the files
LICENSE and COPYING.
The AGPL requires that modified versions offered over a network carry their corresponding source. If you modify Arcadia, publish your changes under the same terms.