diff options
| author | David Palacios <97840947+dpalacios69@users.noreply.github.com> | 2026-11-24 11:54:01 +0100 |
|---|---|---|
| committer | David Palacios <97840947+dpalacios69@users.noreply.github.com> | 2026-11-24 12:06:15 +0100 |
| commit | 48cb4bf039cf84870e2eb020a8b4fd87e508959e (patch) | |
| tree | 47831be1f85c6d25df13f6ebba6d063960ff1b6b /docs/linux.md | |
| parent | 21625bca8c675c62f9dbffc318ce6a59d57faf31 (diff) | |
docs/linux.md: add root-free micromamba setup section (DOC-LINUX-FEDORA-NOROOT)
Diffstat (limited to 'docs/linux.md')
| -rw-r--r-- | docs/linux.md | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/docs/linux.md b/docs/linux.md index e7ca27455..f462aacbb 100644 --- a/docs/linux.md +++ b/docs/linux.md | |||
| @@ -112,3 +112,36 @@ python3 -I tests/test_<name>.py # one standard- | |||
| 112 | 112 | ||
| 113 | [testing.md](testing.md) covers the GPU tests (`scripts/run_gpu_tests.py`), running them on llvmpipe, and choosing | 113 | [testing.md](testing.md) covers the GPU tests (`scripts/run_gpu_tests.py`), running them on llvmpipe, and choosing |
| 114 | the GPU. | 114 | the GPU. |
| 115 | |||
| 116 | ### Without root (micromamba) | ||
| 117 | |||
| 118 | If you cannot install distribution packages (no `sudo`), you can install `llvm-tools` and `spirv-tools` into a | ||
| 119 | user-owned folder with [micromamba](https://mamba.readthedocs.io/en/latest/installation/micromamba-installation.html) | ||
| 120 | (x86-64 glibc; for ARM64 use `linux-aarch64` from the micromamba guide; musl/Alpine is not natively supported) and let | ||
| 121 | CMake fetch its pinned, hash-checked Vulkan headers: | ||
| 122 | |||
| 123 | ```bash | ||
| 124 | LEO=$HOME/leonida-tools | ||
| 125 | mkdir -p "$LEO/bin" "$LEO/mamba" | ||
| 126 | # Note: `latest` is unpinned and downloaded without signature verification; inspect or pin per the micromamba guide. | ||
| 127 | curl -fsSLo "$LEO/micromamba.tar.bz2" https://micro.mamba.pm/api/micromamba/linux-64/latest | ||
| 128 | tar -xjf "$LEO/micromamba.tar.bz2" -C "$LEO/bin" --strip-components=1 bin/micromamba | ||
| 129 | |||
| 130 | export MAMBA_ROOT_PREFIX="$LEO/mamba" | ||
| 131 | "$LEO/bin/micromamba" create -y -n leonida -c conda-forge --override-channels "llvm-tools>=21" spirv-tools | ||
| 132 | export PATH="$LEO/mamba/envs/leonida/bin:$PATH" | ||
| 133 | |||
| 134 | cmake -S runtime -B runtime/build/linux -G Ninja -DCMAKE_BUILD_TYPE=RelWithDebInfo -DLEONIDA_VULKAN_HEADERS_FETCH=ON | ||
| 135 | cmake --build runtime/build/linux --parallel "$(nproc)" | ||
| 136 | LLVM_MC=llvm-mc LEONIDA_VK_DEVICE="<part of your GPU name>" \ | ||
| 137 | python3 -I scripts/run_gpu_tests.py --build runtime/build/linux --work "$LEO/run" --require-pass | tee "$LEO/run.log" | ||
| 138 | echo "runner exit: ${PIPESTATUS[0]}" | ||
| 139 | ``` | ||
| 140 | |||
| 141 | Notes: | ||
| 142 | - `LEONIDA_VK_DEVICE` selects the physical GPU by substring so the runner does not fall back to Mesa's `llvmpipe`. | ||
| 143 | - Keep `$LEO` on a filesystem without `noexec` (`findmnt -no OPTIONS "$LEO"`). | ||
| 144 | - System prerequisites still needed: a working Vulkan driver/loader (`vulkaninfo --summary`), `cmake`, `ninja`, `g++` | ||
| 145 | (or `clang++`), `python3`, `curl`, `tar`, and `bzip2`. | ||
| 146 | - Cleanup: delete `$LEO` and `runtime/build/linux`. micromamba also writes `~/.conda/environments.txt` and | ||
| 147 | `~/.mamba/pkgs/urls.txt` (delete only those files if you already use conda). | ||