相关疑难解决方法(0)

mac上的pyaudio安装(python 3)

我第一次尝试:

pip install pyaudio
Run Code Online (Sandbox Code Playgroud)

但有人告诉我

-bash: pip: command not found
Run Code Online (Sandbox Code Playgroud)

然后我尝试了:

pip3 install pyaudio
Run Code Online (Sandbox Code Playgroud)

然后我得到了:

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
Run Code Online (Sandbox Code Playgroud)

但我安装了portaudio

brew install portaudio
Run Code Online (Sandbox Code Playgroud)

警告:已安装portaudio-19.20140130

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

:)

python pyaudio python-3.4

21
推荐指数
5
解决办法
3万
查看次数

如何在Mac OS X 10.7上的virtualenv中安装PyAudio

我试过了

easy_install pyaudio
Run Code Online (Sandbox Code Playgroud)

它不起作用.我得到以下内容:

Searching for pyaudio
Reading http://pypi.python.org/simple/pyaudio/
Reading http://people.csail.mit.edu/hubert/pyaudio/
Best match: pyaudio 0.2.7
Downloading http://people.csail.mit.edu/hubert/pyaudio/packages/pyaudio-0.2.7.tar.gz
Processing pyaudio-0.2.7.tar.gz
Writing /var/folders/vg/98k5hfl52m16wm45ckdx1_5c0000gp/T/easy_install-s1wLkT/PyAudio-0.2.7/setup.cfg
Running PyAudio-0.2.7/setup.py -q bdist_egg --dist-dir /var/folders/vg/98k5hfl52m16wm45ckdx1_5c0000gp/T/easy_install-s1wLkT/PyAudio-0.2.7/egg-dist-tmp-pFDrFR
warning: no files found matching '*.c' under directory 'test'
clang: warning: argument unused during compilation: '-mno-fused-madd'
src/_portaudiomodule.c:29:10: fatal error: 'portaudio.h' file not found
#include "portaudio.h"
         ^
1 error generated.
error: Setup script exited with error: command 'clang' failed with exit status 1
Run Code Online (Sandbox Code Playgroud)

python macos virtualenv pyaudio

10
推荐指数
2
解决办法
7048
查看次数

无法在 M1 Mac 上安装 PyAudio [PortAudio 已安装]

我访问了很多论坛,尝试了不同的方法,如brew、pip、port 等等,但仍然面临同样的错误。

查看此图片了解更多详情

src/_portaudiomodule.c:29:10: fatal error: 'portaudio.h' file not found
    #include "portaudio.h"
             ^~~~~~~~~~~~~
    1 error generated.
    error: command '/usr/bin/gcc' failed with exit code 1
Run Code Online (Sandbox Code Playgroud)

有人可以帮忙吗?

homebrew pip portaudio pyaudio macos-big-sur

8
推荐指数
3
解决办法
2万
查看次数

无法在osx lion上安装pyaudio

我想在osx lion上安装pyaudio,但我无法做到.每次我尝试使用pkg时,它都不会安装任何东西.当我尝试使用pip安装它时,我有以下错误(在很多其他行中):

lipo: can't open input file: /var/folders/11/gfpzwjdd6dj7hbz7dpbvx9y40000gn/T//ccYnQM1k.out (No such file or directory)
Run Code Online (Sandbox Code Playgroud)

错误:命令'/ usr/bin/llvm-gcc'失败,退出状态为1

如果有人可以帮助我,谢谢.

pyaudio osx-lion

3
推荐指数
1
解决办法
2225
查看次数

安装 PyAudio 出现错误“portaudio.h”文件未找到

我一直在尝试为一个项目安装 PyAudio。我正在使用配备 M1 芯片、操作系统 11.0.1 的 Mac。

每次我运行时pip3 install pyaudio都会遇到同样的错误:

    #include "portaudio.h"
             ^~~~~~~~~~~~~
    1 error generated.
    error: command 'clang' failed with exit status 1
Run Code Online (Sandbox Code Playgroud)

我已经安装了 portaudiobrew install portaudio并拥有 x-code 命令行工具,但它仍然无法工作。我也尝试过将 sudo 放在它前面,但没有成功。

任何帮助表示赞赏!

这是错误的图像: 错误

python pip portaudio pyaudio

3
推荐指数
1
解决办法
2918
查看次数

如何在没有子进程退出并出现错误代码“无法构建轮子”的情况下安装 pyAudio

每次运行 pip install pyaudio 时都会出现以下错误

\n
pip3 install pyaudio\nCollecting pyaudio\n  Using cached PyAudio-0.2.12.tar.gz (42 kB)\n  Installing build dependencies ... done\n  Getting requirements to build wheel ... done\n  Preparing metadata (pyproject.toml) ... done\nBuilding wheels for collected packages: pyaudio\n  Building wheel for pyaudio (pyproject.toml) ... error\n  error: subprocess-exited-with-error\n  \n  \xc3\x97 Building wheel for pyaudio (pyproject.toml) did not run successfully.\n  \xe2\x94\x82 exit code: 1\n  \xe2\x95\xb0\xe2\x94\x80> [16 lines of output]\n      running bdist_wheel\n      running build\n      running build_py\n      creating build\n      creating build/lib.macosx-10.9-universal2-cpython-310\n      copying src/pyaudio.py -> build/lib.macosx-10.9-universal2-cpython-310\n …
Run Code Online (Sandbox Code Playgroud)

python macos pyaudio

-1
推荐指数
1
解决办法
1698
查看次数