0

I am having difficulty install pyaudio for python3 on my MacOSX Sierra. I have installed portaudio using

brew install portaudio

I then try:

pip3 install pyaudio

but get the well known gcc error #include "portaudio.h".

I specified the headers as detailed in a reply to another post by fukudama, as so:

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

However, I now get an error that float.h cannot be found. I know float.h is located in /usr/include/c++/4.2.1/tr1, but I am fairly new to programming and don't know how to include this in my install command. Any help would be really appreciated, thank you!

J Snydes
  • 1
  • 1
  • Did you see this post? https://stackoverflow.com/questions/33851379/pyaudio-installation-on-mac-python-3 – dkato Jan 24 '18 at 02:52
  • Yes I reviewed that post as well. I tried updating xcode as they suggest, but terminal said it was already up to date. – J Snydes Jan 25 '18 at 03:42

1 Answers1

0

the pyaudio does not give any error till version 3.6. I had the same trouble and took quite a time to resolve but the easy way is to install a python version 3.6 and then make sure you run the project on a virtual environment and hence pyaudio is installed without any trouble. i hope it helps.

Ayush Verma
  • 121
  • 1
  • 6