summaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorCayetano Santos <csantosb@inventati.org>2026-08-13 10:59:00 +0200
committerCayetano Santos <csantosb@inventati.org>2026-08-17 16:18:00 +0200
commit30d5740056fce43fede63237bb826f86a3237566 (patch)
tree32fbb6b68002c188d99ee50e03a8b9f8e2118be5 /gnu
parent788a717f0cbbb9afe62488a63682db315c769b17 (diff)
gnu: llama-cpp: Update to 0.0.0-10318.
Former disabled tests in ’fix-tests phase are replaced by a patch. * gnu/packages/machine-learning.scm (llama-cpp): Update to 0.0.0-10318. [source]: Add patch. [arguments]: Remove disabled tests from ’fix-tests #:phase. * gnu/packages/patches/llama-cpp-disable-tests.patch: New file. * gnu/local.mk (dist_patch_DATA): Register it. Merges guix/guix!10535
Diffstat (limited to 'gnu')
-rw-r--r--gnu/local.mk1
-rw-r--r--gnu/packages/machine-learning.scm18
-rw-r--r--gnu/packages/patches/llama-cpp-disable-tests.patch57
3 files changed, 62 insertions, 14 deletions
diff --git a/gnu/local.mk b/gnu/local.mk
index 400f03620b9..7f5352a22f2 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1710,6 +1710,7 @@ dist_patch_DATA = \
1710 %D%/packages/patches/jsonnet-include-cstdint-for-gcc-13-builds.patch \ 1710 %D%/packages/patches/jsonnet-include-cstdint-for-gcc-13-builds.patch \
1711 %D%/packages/patches/julia-SOURCE_DATE_EPOCH-mtime.patch \ 1711 %D%/packages/patches/julia-SOURCE_DATE_EPOCH-mtime.patch \
1712 %D%/packages/patches/julia-Use-MPFR-4.2.patch \ 1712 %D%/packages/patches/julia-Use-MPFR-4.2.patch \
1713 %D%/packages/patches/llama-cpp-disable-tests.patch \
1713 %D%/packages/patches/libcall-ui-make-it-installable.patch \ 1714 %D%/packages/patches/libcall-ui-make-it-installable.patch \
1714 %D%/packages/patches/libcamera-ipa_manager-disable-signature-verification.patch \ 1715 %D%/packages/patches/libcamera-ipa_manager-disable-signature-verification.patch \
1715 %D%/packages/patches/libconfuse-CVE-2022-40320.patch \ 1716 %D%/packages/patches/libconfuse-CVE-2022-40320.patch \
diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index c1bd8444436..706b6e61bef 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -940,7 +940,7 @@ NumPy @code{dtype} extensions used in machine learning libraries, including:
940 (license license:asl2.0))) 940 (license license:asl2.0)))
941 941
942(define-public llama-cpp 942(define-public llama-cpp
943 (let ((tag "9912")) ;sync with ggml and python-gguf 943 (let ((tag "10318")) ;sync with ggml and python-gguf
944 (package 944 (package
945 (name "llama-cpp") 945 (name "llama-cpp")
946 (version (string-append "0.0.0-" tag)) 946 (version (string-append "0.0.0-" tag))
@@ -951,8 +951,10 @@ NumPy @code{dtype} extensions used in machine learning libraries, including:
951 (url "https://github.com/ggml-org/llama.cpp") 951 (url "https://github.com/ggml-org/llama.cpp")
952 (commit (string-append "b" tag)))) 952 (commit (string-append "b" tag))))
953 (file-name (git-file-name name tag)) 953 (file-name (git-file-name name tag))
954 (patches
955 (search-patches "llama-cpp-disable-tests.patch"))
954 (sha256 956 (sha256
955 (base32 "05z59i5461k3xxn8b7jkq5vl31ncx3b4v8xskk35b8djdvrxziyd")))) 957 (base32 "1qpb1hl0mqzcanr844qcbkg9ffmgwckq9q9w51k9xp1qgdpp1r3a"))))
956 (build-system cmake-build-system) 958 (build-system cmake-build-system)
957 (arguments 959 (arguments
958 (list 960 (list
@@ -985,7 +987,6 @@ NumPy @code{dtype} extensions used in machine learning libraries, including:
985 "") 987 "")
986 (("set_tests_properties\\(test-save-load-state.*") 988 (("set_tests_properties\\(test-save-load-state.*")
987 "") 989 "")
988
989 (("llama_build_and_test\\(test-thread-safety.cpp.*") 990 (("llama_build_and_test\\(test-thread-safety.cpp.*")
990 "") 991 "")
991 (("set_tests_properties\\(test-thread-safety.*") 992 (("set_tests_properties\\(test-thread-safety.*")
@@ -995,20 +996,9 @@ NumPy @code{dtype} extensions used in machine learning libraries, including:
995 "") 996 "")
996 (("set_tests_properties\\(test-state-restore-fragmented.*") 997 (("set_tests_properties\\(test-state-restore-fragmented.*")
997 "") 998 "")
998 (("llama_build_and_test\\(test-llama-archs.cpp.*")
999 "")
1000 (("set_tests_properties\\(test-download-model.*")
1001 (string-append "set_tests_properties(test-download-model "
1002 " PROPERTIES DISABLED TRUE)"))
1003 ;; error while handling argument "-m": expected value for 999 ;; error while handling argument "-m": expected value for
1004 ;; argument 1000 ;; argument
1005 (("llama_build_and_test\\(test-arg-parser.cpp.*") 1001 (("llama_build_and_test\\(test-arg-parser.cpp.*")
1006 "")
1007 (((string-append "llama_build_and_test\\"
1008 "(test-recurrent-state-rollback.cpp.*"))
1009 "")
1010 (((string-append "set_tests_properties\\"
1011 "(test-recurrent-state-rollback.*"))
1012 "")) 1002 ""))
1013 ;; test-eval-callback downloads ML model from network, cannot 1003 ;; test-eval-callback downloads ML model from network, cannot
1014 ;; run in Guix build environment 1004 ;; run in Guix build environment
diff --git a/gnu/packages/patches/llama-cpp-disable-tests.patch b/gnu/packages/patches/llama-cpp-disable-tests.patch
new file mode 100644
index 00000000000..31481763d6d
--- /dev/null
+++ b/gnu/packages/patches/llama-cpp-disable-tests.patch
@@ -0,0 +1,57 @@
1From c6de074e5f6bfdd8c6533edab701b8a87fb0e08a Mon Sep 17 00:00:00 2001
2Message-ID: <c6de074e5f6bfdd8c6533edab701b8a87fb0e08a.1786611352.git.csantosb@inventati.org>
3From: Cayetano Santos <csantosb@inventati.org>
4Date: Thu, 13 Aug 2026 10:32:43 +0200
5Subject: [PATCH] 20318
6
7---
8 tests/CMakeLists.txt | 26 --------------------------
9 1 file changed, 26 deletions(-)
10
11diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
12index 419e1eba4..ab1ea6e8e 100644
13--- a/tests/CMakeLists.txt
14+++ b/tests/CMakeLists.txt
15@@ -199,24 +199,6 @@ if (NOT WIN32 OR NOT BUILD_SHARED_LIBS)
16 set(MODEL_DIR "${CMAKE_CURRENT_BINARY_DIR}/test-models/")
17 file(MAKE_DIRECTORY "${MODEL_DIR}")
18
19- llama_test(
20- test-llama-archs
21- NAME test-generate-models
22- LABEL main
23- ARGS -o "${MODEL_DIR}"
24- )
25- set_tests_properties(test-generate-models PROPERTIES
26- FIXTURES_SETUP generate-models
27- )
28-
29- llama_test(
30- test-recurrent-state-rollback
31- LABEL main
32- ARGS -m "${MODEL_DIR}/qwen35-dense.gguf"
33- )
34- set_tests_properties(test-recurrent-state-rollback PROPERTIES
35- FIXTURES_REQUIRED generate-models
36- )
37 endif()
38
39 llama_build_and_test(test-chat-peg-parser.cpp peg-parser/simple-tokenize.cpp)
40@@ -246,14 +228,6 @@ else()
41 endif()
42 set(MODEL_DEST "${CMAKE_BINARY_DIR}/${MODEL_NAME}")
43
44-add_test(NAME test-download-model COMMAND ${CMAKE_COMMAND}
45- -DDEST=${MODEL_DEST}
46- -DNAME=${MODEL_NAME}
47- -DHASH=${MODEL_HASH}
48- -P ${CMAKE_SOURCE_DIR}/cmake/download-models.cmake
49-)
50-set_tests_properties(test-download-model PROPERTIES FIXTURES_SETUP test-download-model)
51-
52 llama_build_and_test(test-thread-safety.cpp ARGS -m "${MODEL_DEST}" -ngl 99 -p "The meaning of life is" -n 128 -c 256 -ub 32 -np 4 -t 2)
53 set_tests_properties(test-thread-safety PROPERTIES FIXTURES_REQUIRED test-download-model)
54
55--
562.54.0
57