Skip to Content
coaadedocs

Build from source

Requirements, CMake presets and GPU build options for StrataFlow on Linux, macOS and Windows.

Requirements

  • CMake 3.20 or newer
  • A C++20 compiler: GCC 11+, Clang 14+ or MSVC 2022
  • Ninja
  • Git (for the vendored llama.cpp/ggml submodule)

Build

git clone https://github.com/Coaade-Inc/strataflow.git
cd strataflow
git submodule update --init --recursive

cmake --preset release
cmake --build build/release

The first build compiles llama.cpp and ggml and takes a few minutes. The tools are written to build/release/bin/:

BinaryPurpose
strataflowRun a model
strata-packConvert a GGUF file to .strata

Presets

PresetUse it for
debugDevelopment. Warnings are errors.
releaseOptimized CPU build
clangBuild with Clang
release-cuda, debug-gpu-cudaNVIDIA GPUs
release-metal, debug-gpu-metalApple GPUs
release-vulkan, debug-gpu-vulkanVulkan GPUs

GPU builds can also be selected with one option: -DSTRATAFLOW_GPU=cuda|metal|vulkan (default off). HIP/ROCm has a lower-level -DSTRATAFLOW_HIP=ON toggle.

A GPU build only uses the GPU when you also pass --device and a GPU is present; otherwise it falls back to the CPU. Full GPU-accelerated execution is still on the roadmap. See Status.

Run the tests

cmake --preset debug
cmake --build build/debug
ctest --preset debug

CI builds and tests on Linux (GCC and Clang), macOS and Windows (MSVC).

Contributing

  • Branch from main and open a pull request into main; CI must pass on all platforms.
  • Keep the build warning-free on GCC, Clang and MSVC.
  • Greedy generation must stay deterministic.
  • Add a test for new engine logic and format with the repository's .clang-format.

Contributions are licensed to Coaade Inc. under the same license.

On this page