bambocher / pocketsphinx-python

Python interface to CMU Sphinxbase and Pocketsphinx libraries
https://pypi.python.org/pypi/pocketsphinx
Other
374 stars 187 forks source link

Trouble installing pocketsphinx-python in python3 #54

Open TLHorse opened 4 years ago

TLHorse commented 4 years ago

My installation:

brew install pcre
brew install swig

then I followed #28:

git clone --recursive https://github.com/bambocher/pocketsphinx-python
cd pocketsphinx-python

Edit file pocketsphinx-python/deps/sphinxbase/src/libsphinxad/ad_openal.c Change

#include <al.h>
#include <alc.h>

to

#include <OpenAL/al.h>
#include <OpenAL/alc.h>

and then:

python setup.py install

But running setup.py can only install the pocketsphinx file into python2 site-packages, but not python3. So, I can import pocketsphinx in python2, but I can't import it in python3.

If you force drag the sphinx file into python3 site-packages folder, it will generate an error during import.

I WANT POCKETSPHINX WORKING IN PYTHON3!

scienceLabwork commented 3 years ago

Try python3 setup.py install