I\'m using mac osx 10.10 As the PyAudio Homepage said, I install the PyAudio using
brew install portaudio
pip install pyaudio
the installa
Just for the record for folks using MacPorts and not Homebrew:
$ [sudo] port install portaudio
$ pip install pyaudio --global-option="build_ext" --global-option="-I/opt/local/include" --global-option="-L/opt/local/lib"
First you can use brew to install portaudio .
brew install portaudio
Then try to find the portaudio path sudo find / -name "portaudio.h"
In my case it is /usr/local/Cellar/portaudio/19.6.0/include
.
Run the below to install pyaudio
pip install --global-option='build_ext' --global-option='-I/usr/local/Cellar/portaudio/19.6.0/include' --global-option='-L/usr/local/Cellar/portaudio/19.6.0/lib' pyaudio
Since pyAudio
has portAudio
as a dependency, you first have to install portaudio.
brew install portaudio
Then try: pip install pyAudio
. If the problem persists after installing portAudio
, you can specify the directory path where the compiler will be able to find the source programs (e.g: portaudio.h
). Since the headers should be in the /usr/local/include
directory:
pip install --global-option='build_ext' --global-option='-I/usr/local/include' --global-option='-L/usr/local/lib' pyaudio
On Raspbian:
sudo apt-get install python-pyaudio