Forum | Documentation | Website | Blog

Skip to content

add python3-snowboy deb package

Jason Kridner requested to merge github/fork/Pillar1989/patch-2 into master

Created by: Pillar1989

how to make python3-snowboy deb package :

sudo apt install  python3-pyaudio sox libpcre3 libpcre3-dev swig libatlas-base-dev python3-stdeb -y
git clone https://github.com/Pillar1989/snowboy
cd snowboy

Modify the setup.py

baozhu@raspberrypi:~/snowboy $ git diff
diff --git a/setup.py b/setup.py
index 3ce2c9d..3963dae 100644
--- a/setup.py
+++ b/setup.py
@@ -13,7 +13,8 @@ class SnowboyBuild(build):
     def run(self):
 
         cmd = ['make']
-        swig_dir = os.path.join('swig', py_dir)
+        print(os.getcwd())
+        swig_dir = os.path.join('../../swig', py_dir)
         def compile():
             call(cmd, cwd=swig_dir)
 baozhu@raspberrypi:~/snowboy $ python3 setup.py --command-packages=stdeb3.command bdist_deb
baozhu@raspberrypi:~/snowboy/deb_dist $ dpkg --contents python3-snowboy_1.3.0-1_all.deb
drwxr-xr-x root/root         0 2020-01-22 17:56 ./
drwxr-xr-x root/root         0 2020-01-22 17:56 ./usr/
drwxr-xr-x root/root         0 2020-01-22 17:56 ./usr/lib/
drwxr-xr-x root/root         0 2020-01-22 17:56 ./usr/lib/python3/
drwxr-xr-x root/root         0 2020-01-22 17:56 ./usr/lib/python3/dist-packages/
drwxr-xr-x root/root         0 2020-01-22 17:56 ./usr/lib/python3/dist-packages/snowboy/
-rw-r--r-- root/root   1000916 2020-01-22 17:22 ./usr/lib/python3/dist-packages/snowboy/_snowboydetect.cpython-37m-arm-linux-gnueabihf.so
drwxr-xr-x root/root         0 2020-01-22 17:56 ./usr/lib/python3/dist-packages/snowboy/resources/
-rw-r--r-- root/root    487498 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/common.res
-rw-r--r-- root/root     15782 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/ding.wav
-rw-r--r-- root/root     12996 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/dong.wav
drwxr-xr-x root/root         0 2020-01-22 17:56 ./usr/lib/python3/dist-packages/snowboy/resources/models/
-rw-r--r-- root/root    793090 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/models/computer.umdl
-rw-r--r-- root/root    793111 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/models/hey_extreme.umdl
-rw-r--r-- root/root   3531994 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/models/jarvis.umdl
-rw-r--r-- root/root   2255028 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/models/neoya.umdl
-rw-r--r-- root/root    832188 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/models/smart_mirror.umdl
-rw-r--r-- root/root    811554 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/models/snowboy.umdl
-rw-r--r-- root/root    793039 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/models/subex.umdl
-rw-r--r-- root/root    793069 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/models/view_glass.umdl
-rw-r--r-- root/root     29952 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/snowboy.raw
-rw-r--r-- root/root     29996 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/resources/snowboy.wav
-rw-r--r-- root/root     10475 2020-01-20 14:04 ./usr/lib/python3/dist-packages/snowboy/snowboydecoder.py
-rw-r--r-- root/root      6343 2020-01-22 17:20 ./usr/lib/python3/dist-packages/snowboy/snowboydetect.py
drwxr-xr-x root/root         0 2020-01-22 17:56 ./usr/lib/python3/dist-packages/snowboy-1.3.0.egg-info/
-rw-r--r-- root/root       259 2020-01-22 17:56 ./usr/lib/python3/dist-packages/snowboy-1.3.0.egg-info/PKG-INFO
-rw-r--r-- root/root         1 2020-01-22 17:56 ./usr/lib/python3/dist-packages/snowboy-1.3.0.egg-info/dependency_links.txt
-rw-r--r-- root/root         1 2020-01-22 17:32 ./usr/lib/python3/dist-packages/snowboy-1.3.0.egg-info/not-zip-safe
-rw-r--r-- root/root         0 2020-01-22 17:56 ./usr/lib/python3/dist-packages/snowboy-1.3.0.egg-info/requires.txt
-rw-r--r-- root/root         8 2020-01-22 17:56 ./usr/lib/python3/dist-packages/snowboy-1.3.0.egg-info/top_level.txt
drwxr-xr-x root/root         0 2020-01-22 17:56 ./usr/share/
drwxr-xr-x root/root         0 2020-01-22 17:56 ./usr/share/doc/
drwxr-xr-x root/root         0 2020-01-22 17:56 ./usr/share/doc/python3-snowboy/
-rw-r--r-- root/root       163 2020-01-22 17:56 ./usr/share/doc/python3-snowboy/changelog.Debian.gz

Merge request reports