From a7941db240cee9a10dec5b775ec7e6705324c0cf Mon Sep 17 00:00:00 2001 From: Evan Reichard Date: Tue, 19 May 2026 20:44:30 -0400 Subject: [PATCH] chore(packages): bump llama-cpp to HEAD 20260519 Update llama-cpp from tagged release b9196 to HEAD build dated 2026-05-19 (rev b28a2f37). Switch to date-based versioning for HEAD builds and update source/webui hashes. Also clarify update-package-hashes skill: always use lib.fakeHash instead of literal sha256 placeholder strings. --- .agents/skills/update-package-hashes/SKILL.md | 2 +- packages/llama-cpp/default.nix | 11 +++++++---- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/.agents/skills/update-package-hashes/SKILL.md b/.agents/skills/update-package-hashes/SKILL.md index 011ffe7..c7b0f88 100644 --- a/.agents/skills/update-package-hashes/SKILL.md +++ b/.agents/skills/update-package-hashes/SKILL.md @@ -49,7 +49,7 @@ grep -E '^[[:space:]]*got:' /tmp/hash.log | tail -1 | awk '{print $2}' Default to `.diff`. Only fall back to `.patch` if you specifically need authorship metadata (rare for Nix patching). If a previously-working `.patch` URL suddenly fails to apply, switching to `.diff` is the first thing to try. -Setting the hash to `lib.fakeHash` (preferred when `lib` is in scope), `sha256-AAAA...` (44 A's), or leaving the old one in place all work — the build will fail at the FOD with `got: sha256-...` which is the correct value. +Always use `lib.fakeHash` (or `pkgs.lib.fakeHash` if only `pkgs` is in scope). This is the only reliable way to set a bogus hash — never write a literal `sha256-...` placeholder string. The build will fail at the FOD with `got: sha256-...` which is the correct value. **Note:** `.src`, `.goModules`, etc. are sub-attributes of the derivation. They download but do not compile. `nix build .#` (without the `.src` suffix) compiles — never do that. diff --git a/packages/llama-cpp/default.nix b/packages/llama-cpp/default.nix index b4f98ba..b3b52aa 100644 --- a/packages/llama-cpp/default.nix +++ b/packages/llama-cpp/default.nix @@ -1,12 +1,15 @@ { pkgs }: let - version = "9196"; + # Version MUST be an integer string. + # For tagged releases use the tag number (e.g. "9222"). + # For HEAD builds use YYYYMMDD (e.g. "20260519"). + version = "20260519"; src = pkgs.fetchFromGitHub { owner = "ggml-org"; repo = "llama.cpp"; - tag = "b${version}"; - hash = "sha256-JOxA7cOoAlQ7It6ogb3Kj2z725b96fkd8jzlvlep3ZU="; + rev = "b28a2f372a4a470a90ad10f93654e5dc33e78949"; + hash = "sha256-SXOpTS3q5Vaik76fg2WQ1mmwAk9+KSMdLe4AErQQlOA="; leaveDotGit = true; postFetch = '' git -C "$out" rev-parse --short HEAD > $out/COMMIT @@ -27,7 +30,7 @@ let name = "llama-webui-${version}-npm-deps"; inherit src; sourceRoot = "${src.name}/tools/ui"; - hash = "sha256-WaEePrEZ7O/7deP2KJhe0AwiSKYA8HOqETmMHUkmBe0="; + hash = "sha256-Iyg8FpcTKf2UYHuK7mA3cTAqVaLcQPcS0YCa5Qf01Gc="; }; webui = pkgs.buildNpmPackage {