GNU bug report logs - #37098
[PATCH 00/20] gnu: Add Tegaki and its inputs.

Previous Next

Package: guix-patches;

Reported by: Alex Vong <alexvong1995 <at> gmail.com>

Date: Tue, 20 Aug 2019 15:38:01 UTC

Severity: normal

Tags: patch

Done: Alex Vong <alexvong1995 <at> gmail.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 37098 in the body.
You can then email your comments to 37098 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 15:38:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Alex Vong <alexvong1995 <at> gmail.com>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Tue, 20 Aug 2019 15:38:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: guix-patches <at> gnu.org
Subject: [PATCH 00/20] gnu: Add Tegaki and its inputs.
Date: Tue, 20 Aug 2019 23:37:24 +0800
[Message part 1 (text/plain, inline)]
Tags: patch

Hello guix,

This patch series adds Tegaki and its inputs, which is an Chinese and
Japanese Handwriting Recognition System. Finally, I can enter
traditional Chinese using free software only! (I don't know any of the
other input methods.)

To use it, install python2-tegaki-recognize and one of the
tegaki-{zinnia,wagomu}-* packages. Then, run "tegaki-recognize -s" to
start the program (the "-s" flag starts the program in simple mode which
is what I prefer).

Should I document this in the guix info page?

---

Stand with Hong Kong!
Alex

https://twitter.com/anti_elab
[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:26:01 GMT) Full text and rfc822 format available.

Message #8 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 01/20] gnu: Add zinnia.
Date: Wed, 21 Aug 2019 00:25:00 +0800
[0001-gnu-Add-zinnia.patch (text/x-diff, inline)]
From 7ce4aad0c29c76d173a7273ee391d4d8a5a471ef Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Tue, 6 Aug 2019 23:43:55 +0800
Subject: [PATCH 01/20] gnu: Add zinnia.

* gnu/packages/ocr.scm (zinnia): New variable.
---
 gnu/packages/ocr.scm | 55 ++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 55 insertions(+)

diff --git a/gnu/packages/ocr.scm b/gnu/packages/ocr.scm
index 2808359ca2..14ea7e443b 100644
--- a/gnu/packages/ocr.scm
+++ b/gnu/packages/ocr.scm
@@ -2,6 +2,7 @@
 ;;; Copyright © 2013 Ludovic Courtès <ludo <at> gnu.org>
 ;;; Copyright © 2016 Efraim Flashner <efraim <at> flashner.co.il>
 ;;; Copyright © 2019 Tobias Geerinckx-Rice <me <at> tobias.gr>
+;;; Copyright © 2019 Alex Vong <alexvong1995 <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -22,6 +23,7 @@
   #:use-module ((guix licenses) #:prefix license:)
   #:use-module (guix packages)
   #:use-module (guix download)
+  #:use-module (guix git-download)
   #:use-module (guix build-system gnu)
   #:use-module (gnu packages compression)
   #:use-module (gnu packages image))
@@ -76,3 +78,56 @@ positional information and page layout analysis.  Several image formats are
 supported through the Leptonica library.  It can also detect whether text is
 monospaced or proportional.")
     (license license:asl2.0)))
+
+(define-public zinnia
+  (let* ((commit "581faa8f6f15e4a7b21964be3a5ec36265c80e5b")
+         (revision "1")
+         ;; version copied from 'configure.in'
+         (version (git-version "0.07" revision commit)))
+    (package
+      (name "zinnia")
+      (version version)
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "https://github.com/taku910/zinnia.git")
+               (commit commit)))
+         (sha256
+          (base32
+           "1izjy5qw6swg0rs2ym2i72zndb90mwrfbd1iv8xbpwckbm4899lg"))
+         (file-name (git-file-name name version))
+         (modules '((guix build utils)
+                    (ice-9 ftw)
+                    (srfi srfi-26)))
+         (snippet ; remove unnecessary files with potentially different license
+          '(begin
+             (for-each delete-file-recursively
+                       (scandir "."
+                                (negate (cut member <> '("zinnia"
+                                                         "." "..")))))
+             #t))))
+      (build-system gnu-build-system)
+      (arguments
+       `(#:phases
+         (modify-phases %standard-phases
+           (replace 'bootstrap
+             (lambda _
+               (chdir "zinnia")
+               (for-each make-file-writable
+                         '("config.log" "config.status"))
+               #t)))))
+      (home-page "https://taku910.github.io/zinnia/")
+      (synopsis "Online hand recognition system with machine learning")
+      (description
+       "Zinnia is a simple, customizable and portable online hand recognition
+system based on Support Vector Machines.  Zinnia simply receives user pen
+strokes as a sequence of coordinate data and outputs n-best characters sorted
+by SVM confidence.  To keep portability, Zinnia doesn't have any rendering
+functionality.  In addition to recognition, Zinnia provides training module
+that allows us to create any hand-written recognition systems with low-cost.")
+      (license (list license:bsd-3 ; all files except...
+                     (license:non-copyleft ; some autotools related files
+                      "file://zinnia/aclocal.m4")
+                     license:x11 ; 'install-sh'
+                     license:public-domain))))) ; 'install-sh'
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:27:02 GMT) Full text and rfc822 format available.

Message #11 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 02/20] gnu: Add python2-zinnia.
Date: Wed, 21 Aug 2019 00:26:26 +0800
[0002-gnu-Add-python2-zinnia.patch (text/x-diff, inline)]
From 0126c99dc0261c2f8d691e825f6c1ef0e99fa9d6 Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Tue, 6 Aug 2019 23:52:41 +0800
Subject: [PATCH 02/20] gnu: Add python2-zinnia.

* gnu/packages/ocr.scm (python2-zinnia): New variable.
---
 gnu/packages/ocr.scm | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

diff --git a/gnu/packages/ocr.scm b/gnu/packages/ocr.scm
index 14ea7e443b..1266e7e419 100644
--- a/gnu/packages/ocr.scm
+++ b/gnu/packages/ocr.scm
@@ -25,7 +25,9 @@
   #:use-module (guix download)
   #:use-module (guix git-download)
   #:use-module (guix build-system gnu)
+  #:use-module (guix build-system python)
   #:use-module (gnu packages compression)
+  #:use-module (gnu packages python)
   #:use-module (gnu packages image))
 
 (define-public ocrad
@@ -131,3 +133,21 @@ that allows us to create any hand-written recognition systems with low-cost.")
                       "file://zinnia/aclocal.m4")
                      license:x11 ; 'install-sh'
                      license:public-domain))))) ; 'install-sh'
+
+;;; python 2 bindings, license under the same terms as zinnia
+(define-public python2-zinnia
+  (package
+    (inherit zinnia)
+    (name "python2-zinnia")
+    (build-system python-build-system)
+    (arguments
+     `(#:python ,python-2 ; CObject API is used, it was removed in Python 3.2
+       #:tests? #f ; avoid circular dependency on tegaki-zinnia-japanese
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'chdir
+           (lambda _
+             (chdir "zinnia/python")
+             #t)))))
+    (inputs
+     `(("zinnia" ,zinnia)))))
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:28:01 GMT) Full text and rfc822 format available.

Message #14 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 03/20] gnu: Add python2-tegaki-wagomu.
Date: Wed, 21 Aug 2019 00:26:48 +0800
[0003-gnu-Add-python2-tegaki-wagomu.patch (text/x-diff, inline)]
From e129c467a7bffd9d304ccf86e0eb317baf1043b7 Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 13:42:46 +0800
Subject: [PATCH 03/20] gnu: Add python2-tegaki-wagomu.

* gnu/packages/language.scm
(python2-tegaki-wagomu, remove-pre-compiled-files-modules): New variables.
(remove-pre-compiled-files, tegaki-release-uri): New procedures.
---
 gnu/packages/language.scm | 75 ++++++++++++++++++++++++++++++++++++++-
 1 file changed, 74 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 73376feecb..cc685437c9 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -2,6 +2,7 @@
 ;;; Copyright © 2015, 2016 Eric Bavier <bavier <at> member.fsf.org>
 ;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me <at> tobias.gr>
 ;;; Copyright © 2018 ng0 <ng0 <at> n0.is>
+;;; Copyright © 2019 Alex Vong <alexvong1995 <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -20,12 +21,17 @@
 
 (define-module (gnu packages language)
   #:use-module (gnu packages)
+  #:use-module (gnu packages glib)
   #:use-module (gnu packages perl)
+  #:use-module (gnu packages pkg-config)
+  #:use-module (gnu packages python)
   #:use-module (gnu packages perl-check)
+  #:use-module (gnu packages swig)
   #:use-module (gnu packages web)
   #:use-module (guix packages)
   #:use-module (guix build-system perl)
-  #:use-module ((guix licenses) #:select (gpl2 gpl3 perl-license))
+  #:use-module (guix build-system python)
+  #:use-module ((guix licenses) #:select (gpl2 gpl2+ gpl3 perl-license))
   #:use-module (guix download))
 
 (define-public perl-lingua-en-findnumber
@@ -406,3 +412,70 @@ string can be easily inferred by a human just by reading the identifier.")
     (description "This module is a rather incomplete implementation of work
 done by Gudrun Putze-Meier.")
     (license perl-license)))
+
+(define* (tegaki-release-uri proj version
+                             #:optional (ext "tar.gz"))
+  (string-append "https://github.com/tegaki/tegaki/releases/download"
+                 "/v" version "/" proj "-" version "." ext))
+
+(define remove-pre-compiled-files
+  (lambda exts
+    "Return snippet for removing pre-compiled files matching one of the
+extensions in EXTS."
+    `(begin (for-each delete-file
+                      (find-files "."
+                                  (lambda (name _)
+                                    (any (cut string-suffix? <> name)
+                                         (map (cut string-append "." <>)
+                                              ',exts)))))
+            #t)))
+
+;;; modules required for the above snippet
+(define remove-pre-compiled-files-modules
+  '((guix build utils)
+    (srfi srfi-1)
+    (srfi srfi-26)))
+
+(define-public python2-tegaki-wagomu
+  (package
+    (name "python2-tegaki-wagomu")
+    (version "0.3.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri "tegaki-wagomu" version))
+       (sha256
+        (base32
+         "1pzdiq4zy1nyylaj9i6v2h4h0r05klahskzpafpp367p4rysi1x9"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "pyc"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:python ,python-2 ; only Python 2 is supported
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'fix-recognizer
+           (lambda* (#:key inputs #:allow-other-keys)
+             ;; fix missing module and function
+             (substitute* "tegakiwagomu.py"
+               (("import Results,")
+                "import ")
+               (("def _recognize")
+                "def recognize")
+               (("Results\\(candidates\\)")
+                "candidates"))
+             #t)))))
+    (inputs
+     `(("glib" ,glib)))
+    (native-inputs
+     `(("pkg-config" ,pkg-config)
+       ("swig" ,swig)))
+    (home-page "https://tegaki.github.io/")
+    (synopsis
+     "Chinese and Japanese Handwriting Recognition (Recognition engine)")
+    (description
+     "Tegaki is an ongoing project which aims to develop a free and open-source
+modern implementation of handwriting recognition software, specifically
+designed for Chinese (simplified and traditional) and Japanese, and that is
+suitable for both the desktop and mobile devices.")
+    (license gpl2+))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:28:02 GMT) Full text and rfc822 format available.

Message #17 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 04/20] gnu: Add python2-tegaki-python.
Date: Wed, 21 Aug 2019 00:27:30 +0800
[0004-gnu-Add-python2-tegaki-python.patch (text/x-diff, inline)]
From e606e1f60f125a402eb13dc807d141b0c9b65fdb Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 13:49:19 +0800
Subject: [PATCH 04/20] gnu: Add python2-tegaki-python.

* gnu/packages/language.scm (python2-tegaki-python): New variable.
---
 gnu/packages/language.scm | 54 +++++++++++++++++++++++++++++++++++++--
 1 file changed, 52 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index cc685437c9..2ef4fed721 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -22,6 +22,7 @@
 (define-module (gnu packages language)
   #:use-module (gnu packages)
   #:use-module (gnu packages glib)
+  #:use-module (gnu packages ocr)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages python)
@@ -31,8 +32,10 @@
   #:use-module (guix packages)
   #:use-module (guix build-system perl)
   #:use-module (guix build-system python)
-  #:use-module ((guix licenses) #:select (gpl2 gpl2+ gpl3 perl-license))
-  #:use-module (guix download))
+  #:use-module ((guix licenses)
+                #:select (bsd-3 gpl2 gpl2+ gpl3 perl-license zpl2.1))
+  #:use-module (guix download)
+  #:use-module (guix utils))
 
 (define-public perl-lingua-en-findnumber
   (package
@@ -479,3 +482,50 @@ modern implementation of handwriting recognition software, specifically
 designed for Chinese (simplified and traditional) and Japanese, and that is
 suitable for both the desktop and mobile devices.")
     (license gpl2+))) ; all files
+
+(define-public python2-tegaki-python
+  (package
+    (inherit python2-tegaki-wagomu)
+    (name "python2-tegaki-python")
+    (version "0.3.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri "tegaki-python" version))
+       (sha256
+        (base32
+         "0x93k7pw9nh0ywd97pr8pm7jv3f94nw044i5k0zvzhdpsjqvak7p"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "pyc"))))
+    (arguments
+     (substitute-keyword-arguments (package-arguments python2-tegaki-wagomu)
+       ((#:phases _)
+        `(modify-phases %standard-phases
+           (add-after 'unpack 'pre-configure
+             (lambda* (#:key inputs #:allow-other-keys)
+               ;; Always convert string to unicode to avoid the following error
+               ;; when running "tegaki-build" in python2-tegaki-tools:
+               ;;
+               ;; sqlite3.ProgrammingError: You must not use 8-bit bytestrings
+               ;; unless you use a text_factory that can interpret 8-bit
+               ;; bytestrings (like text_factory = str).
+               ;; It is highly recommended that you instead just switch your
+               ;; application to Unicode strings.
+               (substitute* "tegaki/charcol.py"
+                 (("sqlite3.OptimizedUnicode")
+                  "lambda s: unicode(s, 'utf-8')"))
+               (substitute* "tegaki/engine.py"
+                 (("/usr(/local)?")
+                  (assoc-ref inputs "python2-tegaki-wagomu")))
+               #t))))))
+    ;; override inherited inputs
+    (inputs '())
+    (native-inputs '())
+    (propagated-inputs
+     `(("python2-tegaki-wagomu" ,python2-tegaki-wagomu)
+       ("python2-zinnia" ,python2-zinnia)))
+    (synopsis
+     "Chinese and Japanese Handwriting Recognition (Base python library)")
+    (license (list gpl2+ ; all files except...
+                   bsd-3 ; dictutils.py
+                   zpl2.1)))) ; minjson.py
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:29:01 GMT) Full text and rfc822 format available.

Message #20 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 05/20] gnu: Add python2-tegaki-pygtk.
Date: Wed, 21 Aug 2019 00:27:58 +0800
[0005-gnu-Add-python2-tegaki-pygtk.patch (text/x-diff, inline)]
From e6f96553078b289da61a325130d0ef2bd0ec41d0 Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 13:53:26 +0800
Subject: [PATCH 05/20] gnu: Add python2-tegaki-pygtk.

* gnu/packages/language.scm (python2-tegaki-pygtk): New variable.
---
 gnu/packages/language.scm | 38 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 38 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 2ef4fed721..bc02ff9681 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -22,6 +22,7 @@
 (define-module (gnu packages language)
   #:use-module (gnu packages)
   #:use-module (gnu packages glib)
+  #:use-module (gnu packages gtk)
   #:use-module (gnu packages ocr)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages pkg-config)
@@ -29,6 +30,7 @@
   #:use-module (gnu packages perl-check)
   #:use-module (gnu packages swig)
   #:use-module (gnu packages web)
+  #:use-module (gnu packages xorg)
   #:use-module (guix packages)
   #:use-module (guix build-system perl)
   #:use-module (guix build-system python)
@@ -529,3 +531,39 @@ suitable for both the desktop and mobile devices.")
     (license (list gpl2+ ; all files except...
                    bsd-3 ; dictutils.py
                    zpl2.1)))) ; minjson.py
+
+(define-public python2-tegaki-pygtk
+  (package
+    (inherit python2-tegaki-wagomu)
+    (name "python2-tegaki-pygtk")
+    (version "0.3.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri "tegaki-pygtk" version))
+       (sha256
+        (base32
+         "1cip0azxhjdj2dg2z85cp1z3lz4qwx3w1j7z4xmcm7npapmsaqs2"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "pyc"))))
+    (arguments
+     (substitute-keyword-arguments (package-arguments python2-tegaki-wagomu)
+       ((#:phases _)
+        `(modify-phases %standard-phases
+           (add-after 'unpack 'fix-paths
+             (lambda* (#:key inputs #:allow-other-keys)
+               (substitute* "tegakigtk/fakekey.py"
+                 (("libX11.so.6" so)
+                  (string-append (assoc-ref inputs "libx11") "/lib/" so))
+                 (("libXtst.so.6" so)
+                  (string-append (assoc-ref inputs "libxtst") "/lib/" so)))
+               #t))))))
+    (inputs ; required for sending key strokes
+     `(("libx11" ,libx11)
+       ("libxtst" ,libxtst)))
+    (native-inputs '()) ; override inherited inputs
+    (propagated-inputs
+     `(("python2-pygtk" ,python2-pygtk)
+       ("python2-tegaki-python" ,python2-tegaki-python)))
+    (synopsis "Chinese and Japanese Handwriting Recognition (Base UI library)")
+    (license gpl2+))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:29:02 GMT) Full text and rfc822 format available.

Message #23 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 06/20] gnu: Add python2-tegaki-tools.
Date: Wed, 21 Aug 2019 00:28:22 +0800
[0006-gnu-Add-python2-tegaki-tools.patch (text/x-diff, inline)]
From 693c0d7fa4e7cda42531986ffb0c5105c8082f0d Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 13:56:56 +0800
Subject: [PATCH 06/20] gnu: Add python2-tegaki-tools.

* gnu/packages/language.scm (python2-tegaki-tools): New variable.
---
 gnu/packages/language.scm | 29 ++++++++++++++++++++++++++++-
 1 file changed, 28 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index bc02ff9681..d12ca7451e 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -35,7 +35,7 @@
   #:use-module (guix build-system perl)
   #:use-module (guix build-system python)
   #:use-module ((guix licenses)
-                #:select (bsd-3 gpl2 gpl2+ gpl3 perl-license zpl2.1))
+                #:select (bsd-3 gpl2 gpl2+ gpl3 gpl3+ perl-license zpl2.1))
   #:use-module (guix download)
   #:use-module (guix utils))
 
@@ -567,3 +567,30 @@ suitable for both the desktop and mobile devices.")
        ("python2-tegaki-python" ,python2-tegaki-python)))
     (synopsis "Chinese and Japanese Handwriting Recognition (Base UI library)")
     (license gpl2+))) ; all files
+
+(define-public python2-tegaki-tools
+  (package
+    (inherit python2-tegaki-wagomu)
+    (name "python2-tegaki-tools")
+    (version "0.3.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri "tegaki-tools" version))
+       (sha256
+        (base32
+         "0xxv97ggh2jgldw3r7y59lv3fhz733r6l7mdn6nh4m0gvb0ja971"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "pyc"))))
+    (arguments
+     (substitute-keyword-arguments (package-arguments python2-tegaki-wagomu)
+       ((#:phases _) '%standard-phases)))
+    (inputs
+     `(("python2-tegaki-pygtk" ,python2-tegaki-pygtk)))
+    ;; override inherited inputs
+    (native-inputs '())
+    (propagated-inputs '())
+    (synopsis "Chinese and Japanese Handwriting Recognition (Advanced tools)")
+    ;; Files in gifenc/ are licensed under gpl3+ while other files are licensed
+    ;; under gpl2+. Therefore, the combined work is licensed under gpl3+.
+    (license gpl3+)))
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:30:02 GMT) Full text and rfc822 format available.

Message #26 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 07/20] gnu: Add python2-tegaki-recognize.
Date: Wed, 21 Aug 2019 00:29:45 +0800
[0007-gnu-Add-python2-tegaki-recognize.patch (text/x-diff, inline)]
From 01a3946b396a3fbd43d2b78fb7bcfda898de5c4b Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:00:36 +0800
Subject: [PATCH 07/20] gnu: Add python2-tegaki-recognize.

* gnu/packages/language.scm (python2-tegaki-recognize): New variable.
---
 gnu/packages/language.scm | 56 ++++++++++++++++++++++++++++++++++++++-
 1 file changed, 55 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index d12ca7451e..ad7cf2a4b3 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -35,8 +35,10 @@
   #:use-module (guix build-system perl)
   #:use-module (guix build-system python)
   #:use-module ((guix licenses)
-                #:select (bsd-3 gpl2 gpl2+ gpl3 gpl3+ perl-license zpl2.1))
+                #:select
+                (bsd-3 gpl2 gpl2+ gpl3 gpl3+ lgpl2.1 perl-license zpl2.1))
   #:use-module (guix download)
+  #:use-module (guix git-download)
   #:use-module (guix utils))
 
 (define-public perl-lingua-en-findnumber
@@ -594,3 +596,55 @@ suitable for both the desktop and mobile devices.")
     ;; Files in gifenc/ are licensed under gpl3+ while other files are licensed
     ;; under gpl2+. Therefore, the combined work is licensed under gpl3+.
     (license gpl3+)))
+
+(define-public python2-tegaki-recognize
+  (let ((commit "eceec69fe651d0733c8c8752dae569d2283d0f3c")
+        (revision "1"))
+    (package
+      (inherit python2-tegaki-tools)
+      (name "python2-tegaki-recognize")
+      ;; version copied from <https://github.com/tegaki/tegaki/releases>
+      (version (git-version "0.3.1" revision commit))
+      (source
+       (origin
+         ;; We use GIT-FETCH because 'tegaki-recognize.desktop.in' and
+         ;; 'tegaki-recognize.in' are missing in the tarball.
+         (method git-fetch)
+         (uri (git-reference
+               (url "https://github.com/tegaki/tegaki.git")
+               (commit commit)))
+         (sha256
+          (base32
+           "09mw2if9p885phbgah5f95q3fwy7s5b46qlmpxqyzfcnj6g7afr5"))
+         (file-name (git-file-name name version))
+         (modules `((guix build utils)
+                    (ice-9 ftw)
+                    (srfi srfi-26)
+                    ,@remove-pre-compiled-files-modules))
+         (snippet
+          `(begin
+             ;; remove unnecessary files with potentially different license
+             (for-each delete-file-recursively
+                       (scandir "."
+                                (negate (cut member <> '("tegaki-recognize"
+                                                         "." "..")))))
+             ,(remove-pre-compiled-files "pyc")
+             #t))))
+      (arguments
+       (substitute-keyword-arguments (package-arguments python2-tegaki-tools)
+         ((#:phases _)
+          `(modify-phases %standard-phases
+             (add-after 'unpack 'chdir
+               (lambda _
+                 (chdir "tegaki-recognize")
+                 #t))
+             ;; 'setup.py' script does not support one of the Python build
+             ;; system's default flags, "--single-version-externally-managed"
+             (replace 'install
+               (lambda* (#:key outputs #:allow-other-keys)
+                 (invoke "python" "setup.py" "install"
+                         (string-append "--prefix=" (assoc-ref outputs "out"))
+                         "--root=/")
+                 #t))))))
+      (synopsis "Chinese and Japanese Handwriting Recognition (Main program)")
+      (license gpl2+)))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:31:02 GMT) Full text and rfc822 format available.

Message #29 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 08/20] gnu: Add tegaki-zinnia-japanese.
Date: Wed, 21 Aug 2019 00:30:09 +0800
[0008-gnu-Add-tegaki-zinnia-japanese.patch (text/x-diff, inline)]
From 6cdacc2aec203aef13de7dfe10da20b9bb61fa04 Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:03:26 +0800
Subject: [PATCH 08/20] gnu: Add tegaki-zinnia-japanese.

* gnu/packages/language.scm (tegaki-zinnia-japanese): New variable.
---
 gnu/packages/language.scm | 38 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 38 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index ad7cf2a4b3..db5a7cb8d2 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -32,6 +32,7 @@
   #:use-module (gnu packages web)
   #:use-module (gnu packages xorg)
   #:use-module (guix packages)
+  #:use-module (guix build-system gnu)
   #:use-module (guix build-system perl)
   #:use-module (guix build-system python)
   #:use-module ((guix licenses)
@@ -648,3 +649,40 @@ suitable for both the desktop and mobile devices.")
                  #t))))))
       (synopsis "Chinese and Japanese Handwriting Recognition (Main program)")
       (license gpl2+)))) ; all files
+
+(define-public tegaki-zinnia-japanese
+  (package
+    (inherit python2-tegaki-wagomu)
+    (name "tegaki-zinnia-japanese")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "1nmg9acxhcqly9gwkyb9m0hpy76fll91ywk4b1q4xms0ajxip1h7"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:tests? #f ; no tests
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'configure
+           (lambda* (#:key outputs #:allow-other-keys)
+             (substitute* "Makefile"
+               (("/usr/local")
+                (assoc-ref outputs "out")))
+             #t)))))
+    ;; override inherited inputs
+    (inputs '())
+    (native-inputs
+     `(("python2-tegaki-tools" ,python2-tegaki-tools)))
+    (propagated-inputs '())
+    (native-search-paths
+     (list (search-path-specification
+            (variable "TEGAKI_MODEL_PATH")
+            (files '("share/tegaki/models")))))
+    (synopsis "Chinese and Japanese Handwriting Recognition (Model)")
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:31:03 GMT) Full text and rfc822 format available.

Message #32 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 09/20] gnu: Add tegaki-zinnia-japanese-light.
Date: Wed, 21 Aug 2019 00:30:29 +0800
[0009-gnu-Add-tegaki-zinnia-japanese-light.patch (text/x-diff, inline)]
From 913b234f4659fd3518dfc7b3d2f114761ee5cb3b Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:14:32 +0800
Subject: [PATCH 09/20] gnu: Add tegaki-zinnia-japanese-light.

* gnu/packages/language.scm (tegaki-zinnia-japanese-light): New variable.
---
 gnu/packages/language.scm | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index db5a7cb8d2..0f834568ea 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -686,3 +686,19 @@ suitable for both the desktop and mobile devices.")
             (files '("share/tegaki/models")))))
     (synopsis "Chinese and Japanese Handwriting Recognition (Model)")
     (license lgpl2.1))) ; all files
+
+(define-public tegaki-zinnia-japanese-light
+  (package
+    (inherit tegaki-zinnia-japanese)
+    (name "tegaki-zinnia-japanese-light")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "0x0fs29ylqzxd6xvg51h7rigpbisd7q8v11df425ib2j792yfyf8"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:31:03 GMT) Full text and rfc822 format available.

Message #35 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 10/20] gnu: Add tegaki-zinnia-japanese-kyoiku.
Date: Wed, 21 Aug 2019 00:30:50 +0800
[0010-gnu-Add-tegaki-zinnia-japanese-kyoiku.patch (text/x-diff, inline)]
From 593f1d9ca20a85aee3c4be474b4de6610ec5131c Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:18:33 +0800
Subject: [PATCH 10/20] gnu: Add tegaki-zinnia-japanese-kyoiku.

* gnu/packages/language.scm (tegaki-zinnia-japanese-kyoiku): New variable.
---
 gnu/packages/language.scm | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 0f834568ea..0eef76d660 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -702,3 +702,19 @@ suitable for both the desktop and mobile devices.")
        (modules remove-pre-compiled-files-modules)
        (snippet (remove-pre-compiled-files "model"))))
     (license lgpl2.1))) ; all files
+
+(define-public tegaki-zinnia-japanese-kyoiku
+  (package
+    (inherit tegaki-zinnia-japanese)
+    (name "tegaki-zinnia-japanese-kyoiku")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "0am94bcpmbzplxdnwn9gk15sgaizvcfhmv13mk14jjvx3419cvvx"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:32:02 GMT) Full text and rfc822 format available.

Message #38 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 11/20] gnu: Add tegaki-zinnia-japanese-joyo.
Date: Wed, 21 Aug 2019 00:31:14 +0800
[0011-gnu-Add-tegaki-zinnia-japanese-joyo.patch (text/x-diff, inline)]
From 0d7fefd99e4109fad581a413a9f915a72134dd20 Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:22:47 +0800
Subject: [PATCH 11/20] gnu: Add tegaki-zinnia-japanese-joyo.

* gnu/packages/language.scm (tegaki-zinnia-japanese-joyo): New variable.
---
 gnu/packages/language.scm | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 0eef76d660..6be09faa99 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -718,3 +718,19 @@ suitable for both the desktop and mobile devices.")
        (modules remove-pre-compiled-files-modules)
        (snippet (remove-pre-compiled-files "model"))))
     (license lgpl2.1))) ; all files
+
+(define-public tegaki-zinnia-japanese-joyo
+  (package
+    (inherit tegaki-zinnia-japanese)
+    (name "tegaki-zinnia-japanese-joyo")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "1v0j40lzdyiz01ayws0b8r7fsdy2mr32658382kz4wyk883wzx2z"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:32:02 GMT) Full text and rfc822 format available.

Message #41 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 12/20] gnu: Add tegaki-zinnia-simplified-chinese.
Date: Wed, 21 Aug 2019 00:31:33 +0800
[0012-gnu-Add-tegaki-zinnia-simplified-chinese.patch (text/x-diff, inline)]
From 63ddc3956b3a1fa0974eb926d95d6f6f84214998 Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:27:15 +0800
Subject: [PATCH 12/20] gnu: Add tegaki-zinnia-simplified-chinese.

* gnu/packages/language.scm (tegaki-zinnia-simplified-chinese): New variable.
---
 gnu/packages/language.scm | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 6be09faa99..9daa579366 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -734,3 +734,19 @@ suitable for both the desktop and mobile devices.")
        (modules remove-pre-compiled-files-modules)
        (snippet (remove-pre-compiled-files "model"))))
     (license lgpl2.1))) ; all files
+
+(define-public tegaki-zinnia-simplified-chinese
+  (package
+    (inherit tegaki-zinnia-japanese)
+    (name "tegaki-zinnia-simplified-chinese")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "18wq0jccv7lpnrfnzspyc110d6pj2v1i21xcx4fmgzz1lnln3fs5"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:33:01 GMT) Full text and rfc822 format available.

Message #44 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 13/20] gnu: Add tegaki-zinnia-simplified-chinese-light.
Date: Wed, 21 Aug 2019 00:31:53 +0800
[0013-gnu-Add-tegaki-zinnia-simplified-chinese-light.patch (text/x-diff, inline)]
From 412d95a65a2f4eab7c42c7f07062e0edd8c44379 Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:30:08 +0800
Subject: [PATCH 13/20] gnu: Add tegaki-zinnia-simplified-chinese-light.

* gnu/packages/language.scm (tegaki-zinnia-simplified-chinese-light): New
variable.
---
 gnu/packages/language.scm | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 9daa579366..13dcd00318 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -750,3 +750,19 @@ suitable for both the desktop and mobile devices.")
        (modules remove-pre-compiled-files-modules)
        (snippet (remove-pre-compiled-files "model"))))
     (license lgpl2.1))) ; all files
+
+(define-public tegaki-zinnia-simplified-chinese-light
+  (package
+    (inherit tegaki-zinnia-japanese)
+    (name "tegaki-zinnia-simplified-chinese-light")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "0v24yf0w0p03lb7fyx128a75mwzad166bigvlbrzqnad789qg1sr"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:33:02 GMT) Full text and rfc822 format available.

Message #47 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 14/20] gnu: Add tegaki-zinnia-traditional-chinese.
Date: Wed, 21 Aug 2019 00:32:18 +0800
[0014-gnu-Add-tegaki-zinnia-traditional-chinese.patch (text/x-diff, inline)]
From 93503c25de95faa0c0b37e68c3677338130e8239 Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:31:45 +0800
Subject: [PATCH 14/20] gnu: Add tegaki-zinnia-traditional-chinese.

* gnu/packages/language.scm (tegaki-zinnia-traditional-chinese): New
variable.
---
 gnu/packages/language.scm | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 13dcd00318..6a0273f0c1 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -766,3 +766,19 @@ suitable for both the desktop and mobile devices.")
        (modules remove-pre-compiled-files-modules)
        (snippet (remove-pre-compiled-files "model"))))
     (license lgpl2.1))) ; all files
+
+(define-public tegaki-zinnia-traditional-chinese
+  (package
+    (inherit tegaki-zinnia-japanese)
+    (name "tegaki-zinnia-traditional-chinese")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "140nlp6hynrai2svs5670jjfw1za6ayflhyj2dl0bzsfgbk3447l"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:34:01 GMT) Full text and rfc822 format available.

Message #50 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 15/20] gnu: Add tegaki-zinnia-traditional-chinese-light.
Date: Wed, 21 Aug 2019 00:33:35 +0800
[0015-gnu-Add-tegaki-zinnia-traditional-chinese-light.patch (text/x-diff, inline)]
From ef8f9faffca8f624ee67f6e8d0ea4a1564a5942a Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:33:27 +0800
Subject: [PATCH 15/20] gnu: Add tegaki-zinnia-traditional-chinese-light.

* gnu/packages/language.scm (tegaki-zinnia-traditional-chinese-light): New
variable.
---
 gnu/packages/language.scm | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 6a0273f0c1..75b702d24e 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -782,3 +782,19 @@ suitable for both the desktop and mobile devices.")
        (modules remove-pre-compiled-files-modules)
        (snippet (remove-pre-compiled-files "model"))))
     (license lgpl2.1))) ; all files
+
+(define-public tegaki-zinnia-traditional-chinese-light
+  (package
+    (inherit tegaki-zinnia-japanese)
+    (name "tegaki-zinnia-traditional-chinese-light")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "1m6yk6a57vs9wg5y50qciwi1ahhmklp2mgsjysbj4mnyzv6yhcr2"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:35:02 GMT) Full text and rfc822 format available.

Message #53 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 16/20] gnu: Add tegaki-wagomu-japanese.
Date: Wed, 21 Aug 2019 00:33:57 +0800
[0016-gnu-Add-tegaki-wagomu-japanese.patch (text/x-diff, inline)]
From 612a6ff02ed2aee717478c46aa41916d71581f8b Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:34:45 +0800
Subject: [PATCH 16/20] gnu: Add tegaki-wagomu-japanese.

* gnu/packages/language.scm (tegaki-wagomu-japanese): New variable.
---
 gnu/packages/language.scm | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 75b702d24e..54e8867f1c 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -798,3 +798,19 @@ suitable for both the desktop and mobile devices.")
        (modules remove-pre-compiled-files-modules)
        (snippet (remove-pre-compiled-files "model"))))
     (license lgpl2.1))) ; all files
+
+(define-public tegaki-wagomu-japanese
+  (package
+    (inherit tegaki-zinnia-japanese)
+    (name "tegaki-wagomu-japanese")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "0flj5id8xwsn7csrrzqz9prdikswnwm2wms0as2vzdpxzph1az4k"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:35:03 GMT) Full text and rfc822 format available.

Message #56 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 17/20] gnu: Add tegaki-wagomu-japanese-kyoiku.
Date: Wed, 21 Aug 2019 00:34:17 +0800
[0017-gnu-Add-tegaki-wagomu-japanese-kyoiku.patch (text/x-diff, inline)]
From 549cc506b25ef09bd3be1cc0d7e9e6cee0f64c25 Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:35:45 +0800
Subject: [PATCH 17/20] gnu: Add tegaki-wagomu-japanese-kyoiku.

* gnu/packages/language.scm (tegaki-wagomu-japanese-kyoiku): New variable.
---
 gnu/packages/language.scm | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 54e8867f1c..ab94f6cba2 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -814,3 +814,19 @@ suitable for both the desktop and mobile devices.")
        (modules remove-pre-compiled-files-modules)
        (snippet (remove-pre-compiled-files "model"))))
     (license lgpl2.1))) ; all files
+
+(define-public tegaki-wagomu-japanese-kyoiku
+  (package
+    (inherit tegaki-zinnia-japanese)
+    (name "tegaki-wagomu-japanese-kyoiku")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "0v8crfh8rdf6ndp16g52s5jlrrlwh73xp38zjn5i9dlacx8kfqg1"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:35:03 GMT) Full text and rfc822 format available.

Message #59 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 18/20] gnu: Add tegaki-wagomu-japanese-joyo.
Date: Wed, 21 Aug 2019 00:34:39 +0800
[0018-gnu-Add-tegaki-wagomu-japanese-joyo.patch (text/x-diff, inline)]
From 2f2f0101797d4993f041dfea82e80d1faf3cb636 Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:37:41 +0800
Subject: [PATCH 18/20] gnu: Add tegaki-wagomu-japanese-joyo.

* gnu/packages/language.scm (tegaki-wagomu-japanese-joyo): New variable.
---
 gnu/packages/language.scm | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index ab94f6cba2..8877dbd817 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -830,3 +830,19 @@ suitable for both the desktop and mobile devices.")
        (modules remove-pre-compiled-files-modules)
        (snippet (remove-pre-compiled-files "model"))))
     (license lgpl2.1))) ; all files
+
+(define-public tegaki-wagomu-japanese-joyo
+  (package
+    (inherit tegaki-zinnia-japanese)
+    (name "tegaki-wagomu-japanese-joyo")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "0wk8shpr963zp328g991qs6abpnacq4242003m687z2d6yp7nph2"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:36:02 GMT) Full text and rfc822 format available.

Message #62 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 19/20] gnu: Add tegaki-wagomu-simplified-chinese.
Date: Wed, 21 Aug 2019 00:35:00 +0800
[0019-gnu-Add-tegaki-wagomu-simplified-chinese.patch (text/x-diff, inline)]
From 233883348d1f36e382dee97a32a89464e92a39fb Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Thu, 8 Aug 2019 14:40:35 +0800
Subject: [PATCH 19/20] gnu: Add tegaki-wagomu-simplified-chinese.

* gnu/packages/language.scm (tegaki-wagomu-simplified-chinese): New variable.
---
 gnu/packages/language.scm | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 8877dbd817..81f96a3870 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -846,3 +846,19 @@ suitable for both the desktop and mobile devices.")
        (modules remove-pre-compiled-files-modules)
        (snippet (remove-pre-compiled-files "model"))))
     (license lgpl2.1))) ; all files
+
+(define-public tegaki-wagomu-simplified-chinese
+  (package
+    (inherit tegaki-zinnia-japanese)
+    (name "tegaki-wagomu-simplified-chinese")
+    (version "0.3")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (tegaki-release-uri name version "zip"))
+       (sha256
+        (base32
+         "0wqprynigqxqxv128i1smh81gxvmjj056d9qpznxa3n9f5ymlbj6"))
+       (modules remove-pre-compiled-files-modules)
+       (snippet (remove-pre-compiled-files "model"))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 20 Aug 2019 16:36:02 GMT) Full text and rfc822 format available.

Message #65 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098 <at> debbugs.gnu.org
Subject: [PATCH 20/20] gnu: Add tegaki-wagomu-traditional-chinese.
Date: Wed, 21 Aug 2019 00:35:17 +0800
[0020-gnu-Add-tegaki-wagomu-traditional-chinese.patch (text/x-diff, inline)]
From e3b093d9a20dcd6fc5bf7b13b2d62921a576398a Mon Sep 17 00:00:00 2001
From: Alex Vong <alexvong1995 <at> gmail.com>
Date: Wed, 14 Aug 2019 16:19:25 +0800
Subject: [PATCH 20/20] gnu: Add tegaki-wagomu-traditional-chinese.

* gnu/packages/language.scm (tegaki-wagomu-traditional-chinese): New
variable.
---
 gnu/packages/language.scm | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)

diff --git a/gnu/packages/language.scm b/gnu/packages/language.scm
index 81f96a3870..1ed2483615 100644
--- a/gnu/packages/language.scm
+++ b/gnu/packages/language.scm
@@ -862,3 +862,24 @@ suitable for both the desktop and mobile devices.")
        (modules remove-pre-compiled-files-modules)
        (snippet (remove-pre-compiled-files "model"))))
     (license lgpl2.1))) ; all files
+
+;;; Upstream does not provide the source for tegaki-wagomu-traditional-chinese.
+;;; Therefore, we use the source for tegaki-zinnia-traditional-chinese and
+;;; patch the Makefile accordingly.
+(define-public tegaki-wagomu-traditional-chinese
+  (package
+    (inherit tegaki-zinnia-traditional-chinese)
+    (name "tegaki-wagomu-traditional-chinese")
+    (arguments
+     (substitute-keyword-arguments
+         (package-arguments tegaki-zinnia-traditional-chinese)
+       ((#:phases phases '%standard-phases)
+        `(modify-phases ,phases
+           (replace 'configure
+             (lambda args
+               (let ((configure (assq-ref ,phases 'configure)))
+                 (apply configure args))
+               (substitute* "Makefile"
+                 (("zinnia") "wagomu"))
+               #t))))))
+    (license lgpl2.1))) ; all files
-- 
2.22.0

[signature.asc (application/pgp-signature, inline)]

Reply sent to Alex Vong <alexvong1995 <at> gmail.com>:
You have taken responsibility. (Tue, 17 Sep 2019 05:45:02 GMT) Full text and rfc822 format available.

Notification sent to Alex Vong <alexvong1995 <at> gmail.com>:
bug acknowledged by developer. (Tue, 17 Sep 2019 05:45:02 GMT) Full text and rfc822 format available.

Message #70 received at 37098-done <at> debbugs.gnu.org (full text, mbox):

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 37098-done <at> debbugs.gnu.org
Subject: Re: [PATCH 00/20] gnu: Add Tegaki and its inputs.
Date: Tue, 17 Sep 2019 13:44:38 +0800
[Message part 1 (text/plain, inline)]
pushed as 9a94ccec4c14dab78326b2b1c449cd4ccd987bcb -
0ed97e69805253656df929a6ad678016aa81f08a

-- 
Stand with Hong Kong!
#passHKHumanRightsDemocracyAct
#BoycottMulan
Alex

https://twitter.com/freedomhkg
https://twitter.com/stand_with_hk
[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#37098; Package guix-patches. (Tue, 17 Sep 2019 09:01:01 GMT) Full text and rfc822 format available.

Message #73 received at 37098 <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Alex Vong <alexvong1995 <at> gmail.com>
Cc: 37098 <at> debbugs.gnu.org
Subject: Re: [bug#37098] [PATCH 00/20] gnu: Add Tegaki and its inputs.
Date: Tue, 17 Sep 2019 11:00:17 +0200
Hi Alex,

Thanks for moving forward and pushing this patch series!

Alex Vong <alexvong1995 <at> gmail.com> skribis:

> This patch series adds Tegaki and its inputs, which is an Chinese and
> Japanese Handwriting Recognition System. Finally, I can enter
> traditional Chinese using free software only! (I don't know any of the
> other input methods.)
>
> To use it, install python2-tegaki-recognize and one of the
> tegaki-{zinnia,wagomu}-* packages. Then, run "tegaki-recognize -s" to
> start the program (the "-s" flag starts the program in simple mode which
> is what I prefer).
>
> Should I document this in the guix info page?

It would probably make sense, perhaps under “Application Setup” and with
appropriate index entries?

BTW, I noticed this:

--8<---------------cut here---------------start------------->8---
starting phase `build'
tegaki-build -c handwriting-zh_TW.xml wagomu handwriting-zh_TW.meta
building of `/gnu/store/gni774zwaiki6sg2jhcisvpsm07i5hhn-tegaki-wagomu-traditional-chinese-0.3.drv' timed out after 3600 seconds of silence
--8<---------------cut here---------------end--------------->8---

This build seems to stick for more than an hour without saying anything.

Do you think it could be sped up or made more verbose?  Otherwise the
build farm will never be patient enough.

Thanks,
Ludo’.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 15 Oct 2019 11:24:08 GMT) Full text and rfc822 format available.

This bug report was last modified 4 years and 187 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.