diff options
| author | xel1uz <hampus.robertsson@gmail.com> | 2026-11-25 05:27:31 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-11-25 05:27:31 +0100 |
| commit | 89b4e9edf28ff76e0ed57dae8e2adbc4a00f381d (patch) | |
| tree | f4eb49f4343bb38abda353a727741800b636e1d6 /runtime/xma_decoder | |
| parent | 1548519aee782ec75868625d58b54f04152220bb (diff) | |
| parent | c7e82e26eadeac237da66949b64e7a52b718361e (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.md | 21 |
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 | ||
| 27 | Without `cargo`, when that build fails, or with the cl.exe fallback of `scripts/build_runtime.ps1`, XMA voices output silence. | 27 | Without `cargo`, when that build fails, or with the cl.exe fallback of `scripts/build_runtime.ps1`, XMA voices output silence. |
| 28 | Use `-DLEONIDA_REQUIRE_XMA2_DECODER=ON` to require the decoder in a CMake build, as the Windows runtime CI does. | 28 | Use `-DLEONIDA_REQUIRE_XMA2_DECODER=ON` to require the decoder in a CMake build, as the Windows runtime CI does. |
| 29 | |||
| 30 | To link an already-built `leonida_xma2_decoder.lib` without invoking `cargo` during CMake configure (for offline builds | ||
| 31 | or 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 | ||
| 33 | back silently to muted XMA voices. | ||
| 34 | |||
| 35 | Build that library yourself, from this checkout's `runtime/xma_decoder`, so that it matches the C ABI the runtime is | ||
| 36 | compiled against. Configure checks only that the file exists, not which source, version or target it was built from, | ||
| 37 | so don't use a library from another checkout, another project or a download: | ||
| 38 | |||
| 39 | ```sh | ||
| 40 | rustup target add x86_64-pc-windows-msvc | ||
| 41 | cargo build --manifest-path runtime/xma_decoder/Cargo.toml --release --locked --target x86_64-pc-windows-msvc | ||
| 42 | ``` | ||
| 43 | |||
| 44 | The library is then `runtime/xma_decoder/target/x86_64-pc-windows-msvc/release/leonida_xma2_decoder.lib`. Building a | ||
| 45 | static library for that target needs only the Rust target, not the MSVC linker, so this also works on Linux. | ||
| 46 | |||
| 47 | With the option set, CMake no longer builds the decoder: after a change under `runtime/xma_decoder/`, run the command | ||
| 48 | again before building the runtime. A relative path given with `-D` on the command line is made absolute against the | ||
| 49 | directory CMake runs in, so passing an absolute path avoids surprises. | ||