Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unable to build pocketsphinx #1

Open
aplsms opened this issue Oct 3, 2020 · 6 comments
Open

unable to build pocketsphinx #1

aplsms opened this issue Oct 3, 2020 · 6 comments

Comments

@aplsms
Copy link

aplsms commented Oct 3, 2020

hello, i have a problem building pocketsphinx

Collecting pocketsphinx
  Using cached pocketsphinx-0.1.15.tar.gz (29.1 MB)
Building wheels for collected packages: pocketsphinx
  Building wheel for pocketsphinx (setup.py) ... error
  ERROR: Command errored out with exit status 1:
   command: /usr/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-3bxdmmdc/pocketsphinx/setup.py'"'"'; __file__='"'"'/tmp/pip-install-3bxdmmdc/pocketsphinx/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-l7rigx5b
       cwd: /tmp/pip-install-3bxdmmdc/pocketsphinx/
  Complete output (239 lines):
  running bdist_wheel
.....
  building 'sphinxbase._ad_pulse' extension
  swigging swig/sphinxbase/ad_pulse.i to swig/sphinxbase/ad_pulse_wrap.c
  swig -python -modern -threads -Ideps/sphinxbase/include -Ideps/sphinxbase/include/sphinxbase -Ideps/sphinxbase/include/android -Ideps/sphinxbase/swig -outdir sphinxbase -o swig/sphinxbase/ad_pulse_wrap.c swig/sphinxbase/ad_pulse.i
  creating build/temp.linux-armv7l-3.7/swig
  creating build/temp.linux-armv7l-3.7/swig/sphinxbase
  creating build/temp.linux-armv7l-3.7/deps/sphinxbase/src/libsphinxad
  arm-linux-gnueabihf-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DSPHINXBASE_EXPORTS -DPOCKETSPHINX_EXPORTS -DSPHINX_DLL -DHAVE_CONFIG_H -Ideps/sphinxbase/include -Ideps/sphinxbase/include/sphinxbase -Ideps/sphinxbase/include/android -I/usr/include/python3.7m -c swig/sphinxbase/ad_pulse_wrap.c -o build/temp.linux-armv7l-3.7/swig/sphinxbase/ad_pulse_wrap.o -Wno-unused-label -Wno-strict-prototypes -Wno-parentheses -Wno-unused-but-set-variable -Wno-unused-variable -Wno-unused-result -Wno-sign-compare -Wno-misleading-indentation
  In file included from deps/sphinxbase/include/sphinxbase/ad.h:44,
                   from swig/sphinxbase/ad_pulse_wrap.c:3046:
  deps/sphinxbase/include/android/sphinx_config.h:11: warning: "SIZEOF_LONG" redefined
   #define SIZEOF_LONG 8

  In file included from /usr/include/python3.7m/pyconfig.h:13,
                   from /usr/include/python3.7m/Python.h:8,
                   from swig/sphinxbase/ad_pulse_wrap.c:150:
  /usr/include/arm-linux-gnueabihf/python3.7m/pyconfig.h:1363: note: this is the location of the previous definition
   #define SIZEOF_LONG 4

  swig/sphinxbase/ad_pulse_wrap.c: In function ‘_wrap_Ad_readinto’:
  swig/sphinxbase/ad_pulse_wrap.c:3735:5: warning: ‘PyObject_AsWriteBuffer’ is deprecated [-Wdeprecated-declarations]
       res2 = PyObject_AsWriteBuffer(obj1, &buf2, &size2);
       ^~~~
  In file included from /usr/include/python3.7m/Python.h:147,
                   from swig/sphinxbase/ad_pulse_wrap.c:150:
  /usr/include/python3.7m/abstract.h:500:17: note: declared here
   PyAPI_FUNC(int) PyObject_AsWriteBuffer(PyObject *obj,
                   ^~~~~~~~~~~~~~~~~~~~~~
  arm-linux-gnueabihf-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DSPHINXBASE_EXPORTS -DPOCKETSPHINX_EXPORTS -DSPHINX_DLL -DHAVE_CONFIG_H -Ideps/sphinxbase/include -Ideps/sphinxbase/include/sphinxbase -Ideps/sphinxbase/include/android -I/usr/include/python3.7m -c deps/sphinxbase/src/libsphinxad/ad_pulse.c -o build/temp.linux-armv7l-3.7/deps/sphinxbase/src/libsphinxad/ad_pulse.o -Wno-unused-label -Wno-strict-prototypes -Wno-parentheses -Wno-unused-but-set-variable -Wno-unused-variable -Wno-unused-result -Wno-sign-compare -Wno-misleading-indentation
  deps/sphinxbase/src/libsphinxad/ad_pulse.c:44:10: fatal error: pulse/pulseaudio.h: No such file or directory
   #include <pulse/pulseaudio.h>
            ^~~~~~~~~~~~~~~~~~~~
  compilation terminated.
  error: command 'arm-linux-gnueabihf-gcc' failed with exit status 1
  ----------------------------------------
  ERROR: Failed building wheel for pocketsphinx
  Running setup.py clean for pocketsphinx
Failed to build pocketsphinx
@adeept
Copy link
Owner

adeept commented Oct 3, 2020 via email

@howardjensen
Copy link

Hi, I have had the same problem during the past week. I tried 4 more time, same problem. ‘ERROR compilation terminated.
Error : command ‘arm-Linux-gnueabilf-bcc’ failed with exit status 1

Adeept support said the problem is tied to the Speech Feature of the Mars Rover

@Tomascjek
Copy link

Hi, I have had the same problem during the past week. I tried 4 more time, same problem. ‘ERROR compilation terminated.
Error : command ‘arm-Linux-gnueabilf-bcc’ failed with exit status 1

Adeept support said the problem is tied to the Speech Feature of the Mars Rover

DITO

@howardjensen
Copy link

howardjensen commented Nov 11, 2020 via email

@detemp
Copy link

detemp commented Dec 26, 2020

Just run the command:

sudo apt-get install libpulse-dev

team Adeept: I have a fix staged for the setup.py file, tested on RPI4-b and can push it into the master branch if you like.

@sbollaerts
Copy link

I tried to install pockesphinx directly with

sudo python3 -m pip install --upgrade pip setuptools wheel
sudo pip3 install --upgrade pocketsphinx

But it still causing an error. I then did

sudo apt-get install python3-pocketsphinx

I don't know if it is a valid workaround: to check if all examples work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants