Commit 7785872
committed
WSLg GPU: NVIDIA userland install + cairo-software fallback toggle
Two coupled changes per operator 2026-05-10 directive
("WSLg + GPU-PV ... NVIDIA Vulkan ICD; option 1 default + option 3
selectable fallback").
1. /usr/libexec/mios/install-nvidia-wsl-userland.sh (NEW): installs
nvidia-driver-libs from NVIDIA's official CUDA repo
(developer.download.nvidia.com/compute/cuda/repos/fedoraN). Pulls:
* /usr/share/vulkan/icd.d/nvidia_icd.x86_64.json
* /usr/lib64/libGLX_nvidia.so.0 + libEGL_nvidia.so.0
* libnvidia-gpucomp / libnvidia-ml RPM versions
* egl-wayland / egl-gbm / egl-x11 platform implementations
Userland-only -- excludes kmod-nvidia* / akmod-nvidia* (kernel
modules don't apply on WSL; /dev/dxg already provides the kernel
bridge). Self-detects WSLg via /dev/dxg + /mnt/wslg, exits
cleanly on bare-metal / Hyper-V / OCI substrates. Idempotent.
Caveat documented inline: NVIDIA's NATIVE Vulkan ICD enumerates
no GPU under WSL because it expects /dev/nvidia* device nodes
that WSL doesn't expose. Vulkan workloads still go through dzn.
Why install anyway: nvidia-smi works; libGLX_nvidia is forward-
compatible when WSL2 eventually exposes /dev/nvidia* or NVIDIA
ships a /dev/dxg-aware Vulkan ICD; flatpak apps that probe for
NVIDIA detection get a real vendor lib to point at.
2. /etc/profile.d/mios-wslg-gpu.sh: added MIOS_GPU_SOFTWARE=1
toggle. Set in shell or ~/.config/environment.d/ to force
cairo + llvmpipe (CPU-only rendering). Slow but always
produces visible content -- escape hatch for apps where the
d3d12 / dzn paths still fail. Default behavior unchanged
(d3d12 + GL renderer).
build-mios.ps1: added overlay-phase invocation of the install
script after the [desktop].flatpaks pass. Runs as root inside the
dev VM via wsl.exe; surfaces install-script's [ok]/[skip]/[warn]
lines through Log-Ok / Log-Warn so the install summary reflects
NVIDIA stack state.
Verified live on running podman-MiOS-DEV: install completes,
nvidia_icd.x86_64.json + libGLX_nvidia.so.0 land at expected
paths. Vulkan loader still picks dzn for actual rendering (per
the WSL caveat above) but the stack is in place for the day WSL
gains /dev/nvidia* visibility.1 parent 967c7ae commit 7785872
2 files changed
Lines changed: 119 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
26 | 40 | | |
27 | 41 | | |
28 | 42 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
0 commit comments