# Error during Picar X Python installation

**URL:** <https://forum.sunfounder.com/t/error-during-picar-x-python-installation/4046>\
**Category:** Robotic kit for Raspberry Pi\
**Created:** [November 23, 2025, 2:09am UTC](https://forum.sunfounder.com/t/error-during-picar-x-python-installation/4046 "2025-11-23T02:09:32Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![glc1972](https://avatars.discourse-cdn.com/v4/letter/g/d07c76/32.png) [@glc1972](https://forum.sunfounder.com/u/glc1972)\
**Post date:** [November 23, 2025, 2:09am UTC](https://forum.sunfounder.com/t/error-during-picar-x-python-installation/4046/1 "2025-11-23T02:09:32Z")

</div>

Hi, I’m trying to install all the Python modules for a Picar X with Rasp Pi4, and I am getting the following error. Any ideas?

Building wheel for pyaudio (pyproject.toml): started

Building wheel for pyaudio (pyproject.toml): finished with status ‘error’

error: subprocess-exited-with-error

× Building wheel for pyaudio (pyproject.toml) did not run successfully.

│ exit code: 1

╰─\> [27 lines of output]

/tmp/pip-build-env-5luzoak8/overlay/local/lib/python3.13/dist-packages/setuptools/dist.py:759: SetuptoolsDeprecationWarning: License classifiers are deprecated.

!!

\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*

Please consider removing the following classifiers in favor of a SPDX license expression:

License :: OSI Approved :: MIT License

See [Writing your pyproject.toml - Python Packaging User Guide](https://packaging.python.org/en/latest/guides/writing-pyproject-toml/#license) for details.

\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*

!!

self.\_finalize\_license\_expression()

running bdist\_wheel

running build

running build\_py

creating build/lib.linux-aarch64-cpython-313/pyaudio

copying src/pyaudio/\__init_\_.py → build/lib.linux-aarch64-cpython-313/pyaudio

running build\_ext

building ‘pyaudio.\_portaudio’ extension

creating build/temp.linux-aarch64-cpython-313/src/pyaudio

aarch64-linux-gnu-gcc -fno-strict-overflow -Wsign-compare -DNDEBUG -g -O2 -Wall -fPIC -I/usr/local/include -I/usr/include -I/usr/include/python3.13 -c src/pyaudio/device\_api.c -o build/temp.linux-aarch64-cpython-313/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/aarch64-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 pyaudio

DEPRECATION: Building ‘srt’ using the legacy setup.py bdist\_wheel mechanism, which will be removed in a future version. pip 25.3 will enforce this behaviour change. A possible replacement is to use the standardized build interface by setting the `–use-pep517` option, (possibly combined with `–no-build-isolation`), or adding a `pyproject.toml` file to the source tree of ‘srt’. Discussion can be found at

Building wheel for srt (setup.py): started

Building wheel for srt (setup.py): finished with status ‘done’

Created wheel for srt: filename=srt-3.5.3-py3-none-any.whl size=22511 sha256=26c69daece8fbbac55de88e47b7b21438b2ddb0fda228fdb81d641371ee0e0ee

Stored in directory: /root/.cache/pip/wheels/ed/9d/54/8e040c593adecbf10de5a6263add15cfefff5a033e33fda8c6

Successfully built robot\_hat sunfounder-voice-assistant srt

Failed to build pyaudio

ERROR: Failed to build installable wheels for some pyproject.toml based projects (pyaudio)

Try to fix it yourself, or contact [service@sunfounder.com](mailto:service@sunfounder.com) with this message

---

<div class="post-metadata">

**Author:** ![SunFounder\_Moderator](https://avatars.discourse-cdn.com/v4/letter/s/34f0e0/32.png) [@SunFounder\_Moderator](https://forum.sunfounder.com/u/SunFounder_Moderator)\
**Post date:** [November 24, 2025, 7:47am UTC](https://forum.sunfounder.com/t/error-during-picar-x-python-installation/4046/3 "2025-11-24T07:47:36Z")

</div>

[![](https://canada1.discourse-cdn.com/flex029/uploads/sunfounder/original/2X/7/755ba22b14c1809b8f4270990d53ee070f3e17b9.png)](https://forum.sunfounder.com/u/sunfounder_moderator)

**[SunFounder\_Moderator](https://forum.sunfounder.com/u/sunfounder_moderator)**

[1m](https://forum.sunfounder.com/t/error-during-picar-x-python-installation/4046/2 "Post date")

To help us analyze and resolve the issue, please provide the complete error messages from your installation process.  
Meanwhile, we recommend the following steps:  
Install the latest version of the Raspberry Pi OS.

Follow the correct tutorial to install all library codes from this guide:

> **[5. Install All the Modules(Important) — SunFounder PiCar-X Kit documentation](https://docs.sunfounder.com/projects/picar-x-v20/en/latest/python/python_start/install_all_modules.html)**

If you encounter an error during the first installation of the robot\_hat library, please try running the sudo python3 install.py command again. This often resolves the issue.

---

<div class="post-metadata">

**Author:** ![glc1972](https://avatars.discourse-cdn.com/v4/letter/g/d07c76/32.png) [@glc1972](https://forum.sunfounder.com/u/glc1972)\
**Post date:** [November 25, 2025, 4:21am UTC](https://forum.sunfounder.com/t/error-during-picar-x-python-installation/4046/4 "2025-11-25T04:21:30Z")

</div>

Okay, I tried running the install command again, and that seemed to work. I will continue with the setup and make sure everything is functional
