Subject: [PATCH 13/19] gnu: Add python-pocketsphinx.

From: phodina <[email-masked]>
Date: Sat, 18 Sep 2021 19:04:27 +0000

* gnu/packages/python-xyz.scm (python-pocketsphinx): New variable.

diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm
index a7a3443707..5f9967ba0e 100644
--- a/gnu/packages/sphinx.scm
+++ b/gnu/packages/sphinx.scm
@@ -45,14 +45,44 @@
   #:use-module (gnu packages graphviz)
   #:use-module (gnu packages image)
   #:use-module (gnu packages imagemagick)
+  #:use-module (gnu packages linux)
+  #:use-module (gnu packages pulseaudio)
   #:use-module (gnu packages python-build)
   #:use-module (gnu packages python-crypto)
   #:use-module (gnu packages python-web)
   #:use-module (gnu packages python-xyz)
+  #:use-module (gnu packages swig)
   #:use-module (gnu packages time)
   #:use-module (gnu packages python-science)
   #:use-module (gnu packages graph))

+(define-public python-pocketsphinx
+  (package
+    (name "python-pocketsphinx")
+    (version "0.1.15")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+	 (url "https://github.com/bambocher/pocketsphinx-python")
+	    (recursive? #t)
+	    (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "18i1jw9138ldxigfcjz6rk9z2c2wc2ng2zdnkzippv45d5izkdz8"))))
+    (build-system python-build-system)
+    (native-inputs
+     `(("python-pytest" ,python-pytest)
+       ("swig" ,swig)))
+    (propagated-inputs
+     `(("pulseaudio" ,pulseaudio)
+       ("alsa-lib" ,alsa-lib)))
+    (home-page "https://github.com/bambocher/pocketsphinx-python")
+    (synopsis "Python interface to CMU Sphinxbase and Pocketsphinx libraries")
+    (description "Python interface to CMU Sphinxbase and Pocketsphinx libraries")
+    (license license:bsd-3)))
+
 (define-public python-sphinx
   (package
     (name "python-sphinx")
--
2.32.0