Repository navigation
Conversation
var_backend now covers all Linux builds llama.cpp publishes, each with the runtime its release workflow builds against: - cuda: CUDA 12 or 13 build chosen from the host driver (<580 -> 12), plus the matching cudart tarball deployed into /opt/llama-cpp - rocm: ubuntu-rocm-<ver>-x64 with the same ROCm release of AMD's TheRock wheels (rocm[libraries]) in a uv venv, added to LD_LIBRARY_PATH; updates follow upstream when the build moves to a newer ROCm - sycl-fp16 / sycl-fp32: oneAPI runtime libraries from Intel's apt repo, registered with ld.so; Level Zero loader from oneapi-src/level-zero and libze-intel-gpu1 from intel/compute-runtime - openvino: libtbb12, OpenCL ICD loader and Level Zero; GGML_OPENVINO_DEVICE is set to GPU when a render node is present auto stays the default (Vulkan with a GPU, otherwise CPU). The rocm->vulkan remap and the "no Linux ROCm/CUDA build" comments are gone, since upstream now ships both. Release lookups use the b tag prefix, the only tags carrying binaries, and updates keep the recorded backend. The install-time variables are now exported from the CT script so app_vars actually reach the container. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Try this script
COMMUNITY_SCRIPTS_URL=https://raw.githubusercontent.com/cosmincc/PVE-DevScripts/feat/llama-cpp-backends \
bash -c "$(curl -fsSL https://raw.githubusercontent.com/cosmincc/PVE-DevScripts/feat/llama-cpp-backends/ct/llama-cpp.sh)"
Against a core branch as wellAdd Useful flags while testing
|
Go test it. |
Requested by Cosmin
✍️ Description
var_backendin the llama.cpp script now covers every Linux prebuilt llama.cpp publishes. Each backend gets the runtime that upstream's.github/workflows/release.ymlbuilds against:autois still the default: Vulkan when a GPU is passed through, otherwise CPU.cudart-llama-*tarball is also deployed into/opt/llama-cpp.ubuntu-rocm-<ver>-x64, plus the same ROCm release of AMD's TheRock wheels (rocm[libraries]==<ver>.*fromstable.repo.amd.com/rocm/whl-next/) in auvvenv under/opt/llama-cpp_data/rocm, which is added toLD_LIBRARY_PATH. On update, the runtime follows when upstream moves the build to a newer ROCm.intel-oneapi-runtime-libsfrom Intel's oneAPI apt repo (viasetup_deb822_repo), with its lib dirs registered inld.so.conf.d. Also installs the Level Zero loader (libze1_*+u24.04_amd64.debfrom oneapi-src/level-zero, as in release.yml) andlibze-intel-gpu1from intel/compute-runtime.ubuntu-openvino-*-x64withlibtbb12,ocl-icd-libopencl1and Level Zero.GGML_OPENVINO_DEVICE=GPUis set when/dev/dri/renderD*exists, otherwiseCPU.Other changes:
ubuntu-rocmandubuntu-cuda. An old install that recordedrocmbut has no ROCm runtime keeps updating as Vulkan.check_for_gh_release/fetch_and_deploy_gh_releaseuse thebtag prefix, because onlybNNNNtags carry binaries. Updates keep the backend recorded in/opt/llama-cpp_data/.backend.var_backend,var_model_repo,var_ctx_size,var_offload_layers,var_api_keyandvar_portare now exported from the CT script. Before this they were declared inapp_varsbut never reached the container. Whenvar_backendis unset, the install asks throughprompt_select(unattended runs default toauto).var_backendoptions and rewrote the backend note.🔗 Related PR / Issue
Link: #2124
✅ Prerequisites (X in brackets)
🏗️ arm64 Support (X in brackets)
var_arm64is left as it was. cpu, vulkan and cuda (13 only) have arm64 assets. rocm, sycl and openvino are x64 only, and the install now stops with a clear error if one of them is picked on arm64.🖥️ Tested on (X in brackets)
🛠️ Type of Change (X in brackets)
README,AppName.md,CONTRIBUTING.md, or other docs.🔍 Code & Security Review (X in brackets)
CODE-AUDIT.md&CONTRIBUTING.mdguidelinesAppName.sh,AppName-install.sh,AppName.json)fetch_and_deploy_gh_release,fetch_and_deploy_codeberg_release,fetch_and_deploy_gl_release, orfetch_and_deploy_from_urlinstead ofgit pull.🤖 AI Assistance (X in brackets)
AGENTS.mdand.github/agents/pve-script-creator.agent.mdas guidance, and the output has been reviewed and corrected to match those guidelines.Claude Code (Claude Opus, low reasoning effort) ported an earlier draft onto the DevScripts versions of the scripts. It checked the helper signatures against community-scripts/core (
check_for_gh_release/fetch_and_deploy_gh_releasetag-prefix argument,prompt_select,setup_hwaccel) and the asset names against the current llama.cpp release (b11609). shellcheck shows only thesourcewarnings every script in the repo has. Not yet tested on a Proxmox host.📋 Additional Information (optional)
Asset names checked against b11609:
ubuntu-cuda-12.8-x64,ubuntu-cuda-13.4-{x64,arm64}(+cudart-tarballs),ubuntu-rocm-10.0-x64,ubuntu-sycl-{fp16,fp32}-x64,ubuntu-openvino-2026.4.1-x64,ubuntu-vulkan-{x64,arm64},ubuntu-{x64,arm64}.📦 Application Requirements (for new scripts)
🌐 Source
.github/workflows/release.ymlfor the per-backend build dependencies)🤖 Generated with Claude Code