mac上的pyaudio安装(python 3)

我第一次尝试:

pip install pyaudio

但有人告诉我

-bash: pip: command not found

然后我尝试了:

pip3 install pyaudio

然后我得到了:

src/_portaudiomodule.c:29:10: fatal error: 'portaudio.h' file not found

#include "portaudio.h"

         ^

1 error generated.

error: command '/usr/bin/clang' failed with exit status 1

----------------------------------------
Command "/Library/Frameworks/Python.framework/Versions/3.4/bin/python3.4 -c "import setuptools, tokenize;__file__='/private/var/folders/77/gz1txkwj2z925vk6jrkx3wp80000gn/T/pip-build-43z_qk7o/pyaudio/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/77/gz1txkwj2z925vk6jrkx3wp80000gn/T/pip-tkf78ih4-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/77/gz1txkwj2z925vk6jrkx3wp80000gn/T/pip-build-43z_qk7o/pyaudio

但我安装了portaudio

brew install portaudio

警告:已安装portaudio-19.20140130

那我该怎么办?
非常感谢,这是我第一次使用pyaudio,所以…….

上一篇:python录制音频


下一篇:python – 无法安装pyaudio,gcc错误