python3Packages.llama-cpp-python: 0.3.16 -> 0.3.22

Changelog: https://llama-cpp-python.readthedocs.io/en/latest/changelog/

Diff: https://github.com/abetlen/llama-cpp-python/compare/v0.3.16...v0.3.22
This commit is contained in:
Ihar Hrachyshka
2026-05-05 18:34:09 -04:00
parent 8c8c8dc85e
commit 6cb474e21d
@@ -4,7 +4,6 @@
gcc13Stdenv,
buildPythonPackage,
fetchFromGitHub,
fetchpatch,
# nativeBuildInputs
cmake,
@@ -41,28 +40,16 @@ let
in
buildPythonPackage.override { stdenv = stdenvTarget; } rec {
pname = "llama-cpp-python";
version = "0.3.16";
version = "0.3.22";
pyproject = true;
src = fetchFromGitHub {
owner = "abetlen";
repo = "llama-cpp-python";
tag = "v${version}";
hash = "sha256-EUDtCv86J4bznsTqNsdgj1IYkAu83cf+RydFTUb2NEE=";
hash = "sha256-Mdz8aTBo3bwoqtjarXnQuNYjcaU+p4HKdMQfSoYwq60=";
fetchSubmodules = true;
};
# src = /home/gaetan/llama-cpp-python;
patches = [
# Fix test failure on a machine with no metal devices (e.g. nix-community darwin builder)
# https://github.com/ggml-org/llama.cpp/pull/15531
(fetchpatch {
url = "https://github.com/ggml-org/llama.cpp/pull/15531/commits/63a83ffefe4d478ebadff89300a0a3c5d660f56a.patch";
stripLen = 1;
extraPrefix = "vendor/llama.cpp/";
hash = "sha256-9LGnzviBgYYOOww8lhiLXf7xgd/EtxRXGQMredOO4qM=";
})
];
dontUseCmakeConfigure = true;
cmakeFlags = [
@@ -75,7 +62,6 @@ buildPythonPackage.override { stdenv = stdenvTarget; } rec {
#
# cc1: error: unknown value native+nodotprod+noi8mm+nosve for -mcpu
(lib.cmakeBool "GGML_NATIVE" false)
(lib.cmakeFeature "GGML_BUILD_NUMBER" "1")
]
++ lib.optionals cudaSupport [
(lib.cmakeBool "GGML_CUDA" true)