Pyaudio Installation Error - 'Command 'Gcc' Failed with Exit Status 1'

Pyaudio installation error - 'command 'gcc' failed with exit status 1'

Found an answer at https://groups.google.com/forum/#!msg/pyo-discuss/ptp_m39ACpI/XgKdK8YGNSoJ

sudo apt-get install portaudio19-dev

ERROR: Command errored out with exit status 1 while installing pyaudio

brew install portaudio

Then:

brew link portaudio

pip install pyAudio

Or if you are using windows:

Go to: https://www.lfd.uci.edu/~gohlke/pythonlibs/#pyaudio

Download the file and then go to its directory in the cmd and type:

For win 32 bit:

pip install PyAudio‑0.2.11‑cp37‑cp37m‑win32.whl

For win 64 bit:

pip install PyAudio‑0.2.11‑cp38‑cp38‑win_amd64.whl

error: command 'gcc' failed with exit status 1 while installing eventlet

Your install is failing because you don't have the python development headers installed. You can do this through apt on ubuntu/debian with:

sudo apt-get install python-dev 

for python3 use:

sudo apt-get install python3-dev

For eventlet you might also need the libevent libraries installed so if you get an error talking about that you can install libevent with:

sudo apt-get install libevent-dev

PyAudio installation always fails on Mac

Very likely you need to specify the directory path where the compiler can find the source programs like portaudio.h.

Under assumption that the headers are in /usr/local/include directory, try to run the below command in the Terminal:

pip install --global-option='build_ext' --global-option='-I/usr/local/include' --global-option='-L/usr/local/lib' pyaudio

setup script exited with error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

Try installing these packages.

sudo apt-get install build-essential autoconf libtool pkg-config python-opengl python-pil python-pyrex python-pyside.qtopengl idle-python2.7 qt4-dev-tools qt4-designer libqtgui4 libqtcore4 libqt4-xml libqt4-test libqt4-script libqt4-network libqt4-dbus python-qt4 python-qt4-gl libgle3 python-dev libssl-dev

sudo easy_install greenlet

sudo easy_install gevent

error: command 'gcc' failed with exit status 1 when trying to install python-language-server

If you read the word message, it tells you what is wrong

./python/py_defines.h:39:10: fatal error: Python.h: No such file or directory

It says it can't find the header file. Ask dnf about what provides it:

sudo dnf provides '*/Python.h'

Then install that package (sudo dnf install ...) and retry your original command.



Related Topics



Leave a reply



Submit