maiken (mkn)
A YAML-driven, cross-platform build tool for C, C++, Obj-C, CUDA, OpenCL and C#.
One mkn.yaml per project. Dependencies are fetched from git and built for you,
profiles cover debug, test and platform variants, and the same file works with gcc, clang,
MSVC, nvcc and hipcc on Linux, macOS, BSD and Windows.
name: hello
main: hello.cpp
mkn build run
Install
Prebuilt binaries are published with every release:
| Platform | Download |
|---|---|
| Linux x86_64 (glibc, portable) | mkn_manylinux |
| Linux arm64 (portable) | mkn_manylinux_arm |
| Linux x86_64 (Ubuntu) | mkn_nix |
| Linux arm64 (Ubuntu) | mkn_arm_linux |
| macOS arm64 | mkn_arm_osx |
| Windows x86_64 | mkn.exe |
curl -Lo mkn https://github.com/mkn/mkn/releases/latest/download/mkn_manylinux
chmod +x mkn && mv mkn ~/.local/bin/ # or anywhere on PATH
mkn -v
A C/C++ compiler and git must be on PATH. On its first run mkn
detects your compiler and writes a default settings file, which the
settings examples extend or replace.
Everyday commands
mkn build | Compile and link, a profile's test: executables too |
mkn test | Run the test executables |
mkn run | Run the executable, with dependency library paths set up |
mkn clean | Delete bin/<profile> |
Combine them, with a profile and a settings file: mkn clean build test -p test -x clang.
Everything else is in the manual.
Settings examples
Compilers, sanitizers, MPI, CUDA and HIP on Linux, macOS and Windows, each built in CI.
Manual
mkn.yaml, settings.yaml, the command line, dependencies and more.