반응형
Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | ||||
4 | 5 | 6 | 7 | 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 | 22 | 23 | 24 |
25 | 26 | 27 | 28 | 29 | 30 | 31 |
Tags
- ubuntu
- 판교
- CLASS
- openAI
- ros
- python
- Torch
- linux
- opencv
- 터미널
- ROS2
- 딥러닝
- Android
- string
- no space left on device
- socketio
- 스팸
- 오블완
- 분당맛집
- tensorflow
- ChatGPT
- 맛집
- GPT
- CUDA
- humble
- timm
- 티스토리챌린지
- error
- TTS
- pytorch
Archives
- Today
- Total
RoBoLoG
[Python] Pyaudio 설치 실패? 본문
오류 메시지
Collecting pyaudio
Downloading PyAudio-0.2.14.tar.gz (47 kB)
|████████████████████████████████| 47 kB 1.8 MB/s
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... done
Building wheels for collected packages: pyaudio
Building wheel for pyaudio (PEP 517) ... error
ERROR: Command errored out with exit status 1:
command: /usr/local/rc_sw/release/Beryl-R1/common/vision_ws/vis_venv/bin/python /tmp/tmpgpm79pzm build_wheel /tmp/tmp_y2qruvn
cwd: /tmp/pip-install-1x_jgzmv/pyaudio
Complete output (18 lines):
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-x86_64-cpython-38
creating build/lib.linux-x86_64-cpython-38/pyaudio
copying src/pyaudio/__init__.py -> build/lib.linux-x86_64-cpython-38/pyaudio
running build_ext
building 'pyaudio._portaudio' extension
creating build/temp.linux-x86_64-cpython-38
creating build/temp.linux-x86_64-cpython-38/src
creating build/temp.linux-x86_64-cpython-38/src/pyaudio
x86_64-linux-gnu-gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -fPIC -I/usr/local/include -I/usr/include -I/usr/local/rc_sw/release/Beryl-R1/common/vision_ws/vis_venv/include -I/usr/include/python3.8 -c src/pyaudio/device_api.c -o build/temp.linux-x86_64-cpython-38/src/pyaudio/device_api.o
src/pyaudio/device_api.c:9:10: fatal error: portaudio.h: No such file or directory
9 | #include "portaudio.h"
| ^~~~~~~~~~~~~
compilation terminated.
error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1
----------------------------------------
ERROR: Failed building wheel for pyaudio
Failed to build pyaudio
ERROR: Could not build wheels for pyaudio which use PEP 517 and cannot be installed directly
해결 방법
위의 오류 메시지를 통해 알 수 있는 문제는 portaudio.h 파일을 찾을 수 없기 때문에 PyAudio를 빌드할 수 없다는 것입니다. portaudio.h는 PortAudio 라이브러리의 헤더 파일로, PyAudio를 설치하기 위해서는 PortAudio 라이브러리가 시스템에 설치되어 있어야 합니다.
이 문제를 해결하기 위해서는 다음 단계를 따라 PortAudio를 설치해야 합니다:
1. PortAudio 라이브러리 설치: 시스템 패키지 관리자를 사용하여 PortAudio 라이브러리를 설치할 수 있습니다. 예를 들어, Ubuntu와 같은 Debian 기반 시스템에서는 libportaudio-dev 패키지를 설치하면 됩니다.
sudo apt-get update sudo apt-get install libportaudio-dev
※ libportaudio-dev 설치가 안되는 경우 libportaudio-ocaml-dev 로 시도해보셔요.
2. PyAudio 설치: PortAudio 라이브러리를 설치한 후, 다시 PyAudio를 설치합니다.
pip install pyaudio
이제 다시 시도하면 PyAudio가 제대로 설치될 것입니다.
728x90
반응형