Building
Building the Compiler & Runtime
Section titled “Building the Compiler & Runtime”To build kura from source, you will need the following:
Using CMake
Section titled “Using CMake”- First, in the root of the directory, setup cmake:
cmake --preset=clang-debug .- Then build:
cmake --build build --target allBuilding against LLVM 20
Section titled “Building against LLVM 20”Kura builds with LLVM 20 as well as LLVM 22 (the code that differs between them is guarded on
LLVM_VERSION_MAJOR). The clang-llvm20-debug preset looks for LLVM 20 where Debian and Ubuntu
(/usr/lib/llvm-20) and Homebrew (llvm@20) install it, and builds in build-llvm20, so it
doesn’t disturb a build against another LLVM:
cmake --preset=clang-llvm20-debug .cmake --build build-llvm20 --target allIf your LLVM 20 is somewhere else, add -DLLVM_DIR=<prefix>/lib/cmake/llvm and
-DClang_DIR=<prefix>/lib/cmake/clang. To pin another version, set -DKURA_LLVM_VERSION=<major>.
Building the Debugger
Section titled “Building the Debugger”Kura comes with a “debugger” - a standalone executable that runs a simple rendering loop to allow you to explore your UI before you integrate it.
To build the kura debugger, you will need the following:
Using CMake
Section titled “Using CMake”- First, you need to enable it using CMake:
cmake --preset=<your preset> . -DKURA_BUILD_DEBUGGER=ON- Then build it:
cmake --build . --target debugger