Installation
You can choose from three installation methods. Please navigate to the one you prefer via the tabs below.
- Static binary
- Nix flake
- From source
You can download a self-contained binary from https://github.com/Kharacternyk/klunok/releases/latest/download/klunok. You can also browse past releases at https://github.com/Kharacternyk/klunok/releases.
Once the file is downloaded, mark it as executable:
chmod +x ~/Downloads/klunok
You can also copy the binary somewhere in your $PATH, for example:
sudo cp ~/Downloads/klunok /bin/
If you skip this step,
do not forget to specify the full path to the binary when invoking Klunok, for example
~/Downloads/klunok.
The binaries should work on all x86-64 Linux systems. They will not work on architectures other than x86-64, for example ARM on Raspberry Pi or 32-bit x86. Please use alternative installation methods for other architectures.
You can install Klunok with a flake-enabled version of the Nix package manager:
nix profile install github:Kharacternyk/klunok/v2
Avoid installing github:Kharacternyk/klunok (without a version tag),
as this is the development version that is more likely to have bugs.
Instead, use github:Kharacternyk/klunok/v2 for the latest stable version.
Installing from source requires a C compiler and the Meson build system.
Meson also depends on the Ninja build system.
Klunok also requires the libseccomp development files and pkg-config.
It uses libseccomp to prevent new executable memory mappings at runtime.
You can install them, for example, with apt:
sudo apt install gcc meson ninja-build libseccomp-dev pkg-config
The version of Meson installed with apt may not be new enough to build Klunok.
In this case, you can install Meson with pip:
sudo apt install pip
sudo pip install meson
Lua is an optional but recommended dependency.
It allows configuring Klunok without recompiling it.
Klunok should work with Lua version 5.2 or newer.
Installing Lua with apt looks like this:
sudo apt install lua5.4
Once the dependencies are installed, get the source from GitHub and install Klunok with Meson. The whole process may look like this, assuming GCC 14 or newer and some hardening applied:
git clone https://github.com/Kharacternyk/klunok
cd klunok
git checkout v2
CC=gcc meson setup build -Dbuildtype=release \
-Dc_args='-fhardened -fsanitize=signed-integer-overflow -fsanitize-trap=signed-integer-overflow' \
-Dc_link_args=-fhardened
cd build
sudo meson install