upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/runtime/xma_decoder
diff options
context:
space:
mode:
authorxel1uz <hampus.robertsson@gmail.com>2026-11-25 05:27:31 +0100
committerGitHub <noreply@github.com>2026-11-25 05:27:31 +0100
commit89b4e9edf28ff76e0ed57dae8e2adbc4a00f381d (patch)
treef4eb49f4343bb38abda353a727741800b636e1d6 /runtime/xma_decoder
parent1548519aee782ec75868625d58b54f04152220bb (diff)
parentc7e82e26eadeac237da66949b64e7a52b718361e (diff)
Merge branch 'ubiquitarianism:main' into fix/glb-inspect-morph-weight-count
Diffstat (limited to 'runtime/xma_decoder')
-rw-r--r--runtime/xma_decoder/README.md21
1 files changed, 21 insertions, 0 deletions
diff --git a/runtime/xma_decoder/README.md b/runtime/xma_decoder/README.md
index 67341e60a..f02bdcb0c 100644
--- a/runtime/xma_decoder/README.md
+++ b/runtime/xma_decoder/README.md
@@ -26,3 +26,24 @@ The `xma2-decoder` workflow builds and runs the C++ smoke test with MSVC. It lin
26 26
27Without `cargo`, when that build fails, or with the cl.exe fallback of `scripts/build_runtime.ps1`, XMA voices output silence. 27Without `cargo`, when that build fails, or with the cl.exe fallback of `scripts/build_runtime.ps1`, XMA voices output silence.
28Use `-DLEONIDA_REQUIRE_XMA2_DECODER=ON` to require the decoder in a CMake build, as the Windows runtime CI does. 28Use `-DLEONIDA_REQUIRE_XMA2_DECODER=ON` to require the decoder in a CMake build, as the Windows runtime CI does.
29
30To link an already-built `leonida_xma2_decoder.lib` without invoking `cargo` during CMake configure (for offline builds
31or Linux cross-builds whose distribution `rustc` omits the `x86_64-pc-windows-msvc` standard library), pass
32`-DLEONIDA_XMA2_DECODER_LIB=<path>`. A value that does not name an existing file fails configure instead of falling
33back silently to muted XMA voices.
34
35Build that library yourself, from this checkout's `runtime/xma_decoder`, so that it matches the C ABI the runtime is
36compiled against. Configure checks only that the file exists, not which source, version or target it was built from,
37so don't use a library from another checkout, another project or a download:
38
39```sh
40rustup target add x86_64-pc-windows-msvc
41cargo build --manifest-path runtime/xma_decoder/Cargo.toml --release --locked --target x86_64-pc-windows-msvc
42```
43
44The library is then `runtime/xma_decoder/target/x86_64-pc-windows-msvc/release/leonida_xma2_decoder.lib`. Building a
45static library for that target needs only the Rust target, not the MSVC linker, so this also works on Linux.
46
47With the option set, CMake no longer builds the decoder: after a change under `runtime/xma_decoder/`, run the command
48again before building the runtime. A relative path given with `-D` on the command line is made absolute against the
49directory CMake runs in, so passing an absolute path avoids surprises.