Building S2-Launcher

How to build the S2-Launcher host for Source 2 games from source.

S2-Launcher is a host that loads Plugify into a Source 2 game without Metamod. Server owners do not need to build it: it comes ready-made in the build. This page is for those who want to change the host or build it themselves.

Prerequisites

The same as for the core: a C++23 compiler, CMake, Ninja and Git. The official Linux builds are made with GCC 14 in the Steam Runtime container registry.gitlab.steamos.cloud/steamrt/sniper/sdk, so that the result runs on the game server. A build made on another distribution reports that distribution as its platform (see Platforms).

Building

Clone the repository with submodules

The core, the Source 2 SDK and other libraries are Git submodules:

git clone https://github.com/untrustedmodders/plugify-source2-launcher.git --recursive
cd plugify-source2-launcher

Configure and build

cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
cmake --build build --target plugify-source2-launcher

Two kinds of build

The S2_LAUNCHER option chooses what is built:

S2_LAUNCHERResultHow it is used
OFF (default)Shared library libserver_valve.so / server_valve.dllThe game loads it in place of its own server library. It starts Plugify and passes everything else to the real server library
ONExecutable s2launcher / s2launcher.exeStarted instead of the game executable, it loads the engine itself

The build folder also gets libplugify.so / plugify.dll of the core (in build/external/plugify) and micromamba, the package manager the host uses.

Where each file goes on the server is shown in S2-Launcher installation.