- Clone the repository with
--recurse-submodulesor rungit submodule --init --recursive - Download and install Protoc and ensure
protocis in yourPATH
Bootstrap the workspace from the repository root:
melos bootstrapThis installs dependencies, generates proto bindings, and runs code generation.
First you need to generate the FFI bindings:
cd Launcher
dart run tool/ffigen.dartFrom the launcher directory, run:
flutter runFrom the launcher directory, run:
flutter build <platform>To build the installer on Windows, you can use Inno Setup with the provided installer.iss script located in the installer folder.
cd CLI
flutter pub get
flutter_rust_bridge_codegen generate
dart build cli bin/kyber_cli.dartThis will output the binary to build/cli/<platform>/bundle/bin/.
To run the CLI, make sure to copy the rust library from build/cli/<platform>/bundle/lib/ next to the binary.
Important: Make sure to build Maxima first. Then depending on your platform, copy the following files next to the binary from the Maxima build output:
maxima-service.exemaxima-bootstrap.exe
maxima-bootstrap
The KYBER Module can only be compiled on Windows, with MSVC.
First, install bazelisk and drop it into your PATH as bazel.exe.
There is a bug with the gRPC client version we're using in combination with Bazel's long build paths, which makes some build paths extend past the legacy Windows path limit. To work around this, make a folder named bz at the root of your drive. We'll be using this folder to store bazel's intermediary files.
Ensure you have MSYS2 installed to C:\msys64.
Run bazel --output_user_root="C:\bz" build --config=release Kyber. This will take a while. Once it's done, you should have Module/bazel-bin/Kyber.dll. You may alternatively run the build.bat file in the root by running .\build.bat and modifying the path to the correct drive.
Important: The module requires the --config=release flag. Building without it (i.e., in debug mode) will lead to crashes.
Once built, copy Module/bazel-bin/Kyber.dll to C:/ProgramData/Kyber/Module/Kyber.dll to test your changes with the Launcher or CLI.
The KYBER module is primarily developed using Visual Studio Code with the clangd extension. compile_commands.json can be generated by running clangd/refresh.bat while inside the Module folder.
Requires Go 1.24+ and protoc with Go plugins:
go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latestBuild:
Linux:
cd API
./scripts/gen-proto.sh
go build -o kyber-api ./cmd/serverWindows:
cd API
scripts\gen-proto.bat
go build -o kyber-api.exe ./cmd/serverRequires Rust nightly and protoc.
cd Proxy
cargo build --releaseOutput: target/release/kyber_proxy