feat(pdfcraft): add PdfCraft 0.18.0 built from source
CI / check (push) Has been cancelled

Packages the storytold/pdfcraft Cargo workspace at tag v0.18.0: the pdfcraft
desktop app and pdfcraft-cli, with the desktop entry, AppStream metadata,
icons, licences and the two CC-BY-SA OCR models the app reads from
share/pdfcraft/models. No upstream binaries are downloaded.

Two deviations from upstream's build instructions:

- The three [patch.crates-io] entries upstream's own Cargo.lock records as
  [[patch.unused]] (egui_demo_lib, egui_inspection, egui_system_font_provider)
  have no package in nixpkgs' partial vendor tree to resolve against, so cargo
  aborts. postPatch drops them; they are unused, and cargo drops the matching
  lock entries itself, so the build runs without --locked.

- nixos-unstable's rustc 1.98.1 and 1.99.0 reject every AVX-VNNI intrinsic
  ("intrinsic signature mismatch for llvm.x86.avx512.vpdpbusd/vpwssd"), and
  rten-gemm, pic-scale and zlib-rs all use one. The package therefore builds
  against a new nixpkgs-rust195 input (nixos-26.05, rustc 1.95.0), the same
  pattern as nixpkgs-torch211. Follow-up: nix-overlay-g4w.

Also adds a Home Manager module (programs.pdfcraft) to
homeManagerModules.default, and documents both in the README.
This commit is contained in:
2026-11-03 13:48:55 +03:00
parent d05ca58ee6
commit 43199e5b8b
7 changed files with 267 additions and 1 deletions
+10 -1
View File
@@ -11,6 +11,12 @@
# nixpkgs revision for freetoken so its CUDA 12.9 / torch 2.11 stack is
# unchanged.
nixpkgs-torch211.url = "github:NixOS/nixpkgs/549bd84d6279f9852cae6225e372cc67fb91a4c1";
# nixos-unstable's Rust 1.98/1.99 cannot assemble AVX-VNNI intrinsics: every call to
# _mm512_dpbusd_epi32 / _mm512_dpwssd_epi32 / _mm*_dpwssd_avx_epi32 fails with
# "intrinsic signature mismatch for llvm.x86.avx512.vpdp*" against its LLVM 21.1.8. pdfcraft
# needs rustc >= 1.95 and pulls that instruction in through rten-gemm, pic-scale and zlib-rs, so
# it builds against stable's 1.95.0, which assembles them fine.
nixpkgs-rust195.url = "github:NixOS/nixpkgs/nixos-26.05";
systems.url = "github:nix-systems/default";
blueprint = {
url = "github:numtide/blueprint";
@@ -59,7 +65,10 @@
};
homeManagerModules.default = {
imports = [ ./modules/open-code-review-hm.nix ];
imports = [
./modules/open-code-review-hm.nix
./modules/pdfcraft-hm.nix
];
};
};
}