gpt4 book ai didi

python - pip install matplotlib 在 Raspbian Jessie 4.4 上失败

转载 作者:太空宇宙 更新时间:2023-11-04 02:51:51 24 4
gpt4 key购买 nike

我正在尝试通过全新安装 Raspbian Jessie(撰写本文时为 4.4)在树莓派上安装 matplotlib。我正在尝试为 Python 2.7 安装 matplotlib。

我不断收到以下错误:

command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip-build-HPuMoo/matplotlib/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-l3s1dW-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /tmp/pip-build-HPuMoo/matplotlib

Storing debug log for failure in /home/pi/.pip/pip.log

使事情复杂化......当我安装其他软件包时不会发生这种情况(只是安装 virtualenv 没有问题)但是当我尝试升级 numpy 时它确实发生了。

此外,在 Python 的主要发行版 (/usr/bin/python) 或虚拟环境 (/home/pi/Envs/test/bin/python) 上工作时会发生此错误。然后,我在主要发行版上使用 pip 1.5.6,在 virtualenv 上使用 9.0.1。都失败了。 :(

不确定为什么我会遇到这个问题...考虑到 matplotlib 的广泛使用(以及 Jessie 加载的 python 包的数量),你会认为不会有问题。嗯。

最佳答案

根据 this answer by Peter Brittain and Anshuman Chhabra ,安装 libpulse-devpython-dev 库应该可以解决您的问题。如图所示Debian Packages references ,这些库的文件列表包括所需的文件。

关于python - pip install matplotlib 在 Raspbian Jessie 4.4 上失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43613666/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com