我正在尝试在 Ubuntu 22.10 上安装 [pyo][1],但一直出现此 legacy-install-failure 错误。我似乎找不到任何文档。我已经更新了 pip、setuptools 和 wheels。任何建议都将不胜感激。
Collecting pyo
Using cached pyo-1.0.4.tar.gz (6.1 MB)
Preparing metadata (setup.py) ... done
Building wheels for collected packages: pyo
Building wheel for pyo (setup.py) ... error
error: subprocess-exited-with-error
× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
x86_64-linux-gnu-gcc -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DUSE_PORTAUDIO -DUSE_PORTMIDI -DUSE_OSC -Iinclude -I/usr/include -I/usr/local/include -I/usr/include/python3.10 -c src/engine/ad_portaudio.c -o build/temp.linux-x86_64-3.10/src/engine/ad_portaudio.o -Wno-strict-prototypes -Wno-strict-aliasing -O3 -g0 -DNDEBUG
In file included from src/engine/ad_portaudio.c:21:
include/ad_portaudio.h:25:10: fatal error: portaudio.h: No such file or directory
25 | #include "portaudio.h"
| ^~~~~~~~~~~~~
compilation terminated.
error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pyo
Running setup.py clean for pyo
Failed to build pyo
Installing collected packages: pyo
Running setup.py install for pyo ... error
error: subprocess-exited-with-error
× Running setup.py install for pyo did not run successfully.
│ exit code: 1
╰─> [316 lines of output]
x86_64-linux-gnu-gcc -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DUSE_PORTAUDIO -DUSE_PORTMIDI -DUSE_OSC -Iinclude -I/usr/include -I/usr/local/include -I/usr/include/python3.10 -c src/engine/ad_portaudio.c -o build/temp.linux-x86_64-3.10/src/engine/ad_portaudio.o -Wno-strict-prototypes -Wno-strict-aliasing -O3 -g0 -DNDEBUG
In file included from src/engine/ad_portaudio.c:21:
include/ad_portaudio.h:25:10: fatal error: portaudio.h: No such file or directory
25 | #include "portaudio.h"
| ^~~~~~~~~~~~~
compilation terminated.
error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
× Encountered error while trying to install package.
╰─> pyo
note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.