Skip to content

Commit c518609

Browse files
committedMar 21, 2025
python3Packages.llama-cpp-python: 0.3.6 -> 0.3.8
diff: abetlen/llama-cpp-python@v0.3.6...v0.3.8
1 parent 794c70d commit c518609

File tree

1 file changed

+7
-14
lines changed
  • pkgs/development/python-modules/llama-cpp-python

1 file changed

+7
-14
lines changed
 

‎pkgs/development/python-modules/llama-cpp-python/default.nix

+7-14
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
gcc13Stdenv,
55
buildPythonPackage,
66
fetchFromGitHub,
7-
fetchpatch2,
87

98
# nativeBuildInputs
109
cmake,
@@ -40,28 +39,19 @@ let
4039
in
4140
buildPythonPackage rec {
4241
pname = "llama-cpp-python";
43-
version = "0.3.6";
42+
version = "0.3.8";
4443
pyproject = true;
4544

4645
src = fetchFromGitHub {
4746
owner = "abetlen";
4847
repo = "llama-cpp-python";
4948
tag = "v${version}";
50-
hash = "sha256-d5nMgpS7m6WEILs222ztwphoqkAezJ+qt6sVKSlpIYI=";
49+
hash = "sha256-F1E1c2S1iIL3HX/Sot/uIIrOWvfPU1dCrHx14A1Jn9E=";
5150
fetchSubmodules = true;
51+
deepClone = true;
5252
};
5353
# src = /home/gaetan/llama-cpp-python;
5454

55-
patches = [
56-
# fix segfault when running tests due to missing default Metal devices
57-
(fetchpatch2 {
58-
url = "https://github.com/ggml-org/llama.cpp/commit/acd38efee316f3a5ed2e6afcbc5814807c347053.patch?full_index=1";
59-
stripLen = 1;
60-
extraPrefix = "vendor/llama.cpp/";
61-
hash = "sha256-71+Lpg9z5KPlaQTX9D85KS2LXFWLQNJJ18TJyyq3/pU=";
62-
})
63-
];
64-
6555
dontUseCmakeConfigure = true;
6656
SKBUILD_CMAKE_ARGS = lib.strings.concatStringsSep ";" (
6757
# Set GGML_NATIVE=off. Otherwise, cmake attempts to build with
@@ -72,7 +62,10 @@ buildPythonPackage rec {
7262
# -mcpu, breaking linux build as follows:
7363
#
7464
# cc1: error: unknown value ‘native+nodotprod+noi8mm+nosve’ for ‘-mcpu’
75-
[ "-DGGML_NATIVE=off" ]
65+
[
66+
"-DGGML_NATIVE=off"
67+
"-DGGML_BUILD_NUMBER=1"
68+
]
7669
++ lib.optionals cudaSupport [
7770
"-DGGML_CUDA=on"
7871
"-DCUDAToolkit_ROOT=${lib.getDev cudaPackages.cuda_nvcc}"

0 commit comments

Comments
 (0)
Failed to load comments.