簡體   English   中英

錯誤:嘗試使用pip安裝pocketsphinx時,pocketsphinx的構建輪失敗

[英]ERROR: Failed building wheel for pocketsphinx while trying to install pocketsphinx with pip

我正在嘗試安裝 pocketsphinx 並收到以下錯誤:

jandornhege@JanDornhegeUbuntu:~/Hermes/Basefunktions$ pip install pocketsphinx
Collecting pocketsphinx
  Using cached https://files.pythonhosted.org/packages/cd/4a/adea55f189a81aed88efa0b0e1d25628e5ed22622ab9174bf696dd4f9474/pocketsphinx-0.1.15.tar.gz
Building wheels for collected packages: pocketsphinx
  Building wheel for pocketsphinx (setup.py) ... error
  ERROR: Complete output from command /home/jandornhege/anaconda3

.....

  deps/sphinxbase/src/libsphinxad/ad_pulse.c:44:10: fatal error: pulse/pulseaudio.h: Datei oder Verzeichnis nicht gefunden
   #include <pulse/pulseaudio.h>
            ^~~~~~~~~~~~~~~~~~~~
  compilation terminated.
  error: command 'gcc' failed with exit status 1
  ----------------------------------------
  ERROR: Failed building wheel for pocketsphinx

Ubuntu安裝要求

sudo apt-get install -qq python python-dev python-pip build-essential swig git libpulse-dev libasound2-dev

這種情況很常見。 嘗試:

sudo apt-get install pulseaudio swig libpulse-dev

這三個是我經常看到的缺失。 如果您仍然遇到錯誤,請嘗試安裝@ phd提到的其他軟件包。

盡管@DanielMzLz建議不起作用(發生了很多錯誤),但我嘗試了@phd提到的方法 ,然后我添加了:

pip install pocketsphinx

而且有效。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM