iOS   发布时间:2022-05-04  发布网站:大佬教程  code.js-code.com
大佬教程收集整理的这篇文章主要介绍了python – 安装Matplotlib错误 – clang大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。

概述

我试图安装Matplot lib,但我仍然在努力克服错误. 我安装了numpy和psipy,但是当我使用easy_install时出现以下错误(与pip有类似的错误). 是的,我已经在xcode中安装了命令行工具,以解决’gcc-4.2 not found’问题. pymods ['pylab'] packages ['matplotlib', 'matplotlib.BACkends', 'ma
我试图安装Matplot lib,但我仍然在努力克服错误.

我安装了numpy和psipy,但是当我使用easy_install时出现以下错误(与pip有类似错误).

是的,我已经在Xcode中安装了命令行工具,以解决’gcc-4.2 not found’问题.

pymods ['pylab']
packages ['matplotlib','matplotlib.BACkends','matplotlib.BACkends.qt4_editor','matplotlib.projections','matplotlib.tesTing','matplotlib.tesTing.jpl_units','matplotlib.tests','mpl_toolkits','mpl_toolkits.mplot3d','mpl_toolkits.axes_grid','mpl_toolkits.axes_grid1','mpl_toolkits.axisartist','matplotlib.sphinxext','matplotlib.tri','matplotlib.delaunay','pytz','dateutil','dateutil.zoneinfo']
warning: no files found matching 'KNowN_BUGS'
warning: no files found matching 'INTERACTIVE'
warning: no files found matching 'MANIFEST'
warning: no files found matching '__init__.py'
warning: no files found matching 'examples/data/*'
warning: no files found matching 'lib/mpl_toolkits'
warning: no files found matching 'LICENSE*' under directory 'license'
gcc-4.2 not found,using clang instead
In file included from src/ft2font.cpp:3:
src/ft2font.h:16:10: Fatal error: 'ft2build.h' file not found
#include <ft2build.h>
     ^
1 error generated.
error: Setup script exited with error: command 'clang' Failed with exit status 1

解决方法

我最近也有这个问题,但我正在使用pip.如果安装了 homebrew,则可以通过运行以下命令来解决此问题:

brew install freetype
brew install libpng
brew link freetype
pip install git+https://github.com/matplotlib/matplotlib.git#egg=matplotlib-dev

大佬总结

以上是大佬教程为你收集整理的python – 安装Matplotlib错误 – clang全部内容,希望文章能够帮你解决python – 安装Matplotlib错误 – clang所遇到的程序开发问题。

如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。

本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。