guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#71787] [PATCH 08/12] gnu: Add mupdf/tesseract.


From: David Elsing
Subject: [bug#71787] [PATCH 08/12] gnu: Add mupdf/tesseract.
Date: Wed, 26 Jun 2024 19:27:01 +0000

* gnu/packages/pdf.scm (mupdf/tesseract): New variable.
---
 gnu/packages/pdf.scm | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/gnu/packages/pdf.scm b/gnu/packages/pdf.scm
index 232cafcbf1..9e10264fad 100644
--- a/gnu/packages/pdf.scm
+++ b/gnu/packages/pdf.scm
@@ -966,6 +966,20 @@ (define-public mupdf
                    license:silofl1.1    ;resources/fonts/{han,noto,sil,urw}
                    license:asl2.0)))) ; resources/fonts/droid
 
+(define-public mupdf/tesseract
+  (package/inherit mupdf
+    (name (string-append (package-name mupdf) "-with-tesseract"))
+    (inputs (modify-inputs (package-inputs mupdf)
+              (prepend leptonica tesseract-ocr)))
+    (arguments
+     (substitute-keyword-arguments (package-arguments mupdf)
+       ((#:make-flags flags)
+        #~(cons*
+           "tesseract=yes"
+           "USE_SYSTEM_LEPTONICA=yes"
+           "USE_SYSTEM_TESSERACT=yes"
+           #$flags))))))
+
 (define-public qpdf
   (package
     (name "qpdf")
-- 
2.45.1






reply via email to

[Prev in Thread] Current Thread [Next in Thread]