python-3.x - 在 FreeBSD 上使用 pip3 安装 matplotlib 失败

标签 python-3.x matplotlib pip freebsd

我总是收到以下错误消息

freebsd@paratudo:~/anythingCollector % sudo pip3 install matplotlib
Collecting matplotlib
  Using cached matplotlib-1.5.0.tar.gz
    Complete output from command python setup.py egg_info:
    IMPORTANT WARNING:
        pkg-config is not installed.
        matplotlib may not be able to find some of its dependencies
    ============================================================================
    Edit setup.cfg to change the build options

    BUILDING MATPLOTLIB
                matplotlib: yes [1.5.0]
                    python: yes [3.4.3 (default, Nov  5 2015, 01:26:40)  [GCC
                            4.2.1 Compatible FreeBSD Clang 3.4.1
                            (tags/RELEASE_34/dot1-final 208032)]]
                  platform: yes [freebsd10]

    REQUIRED DEPENDENCIES AND EXTENSIONS
                     numpy: yes [version 1.10.1]
                  dateutil: yes [dateutil was not found. It is required for date
                            axis support. pip/easy_install may attempt to
                            install it after matplotlib.]
                      pytz: yes [using pytz version 2015.7]
                    cycler: yes [cycler was not found. pip will attempt to
                            install it after matplotlib.]
                   tornado: yes [using tornado version 4.3]
                 pyparsing: yes [using pyparsing version 2.0.6]
                    libagg: yes [pkg-config information for 'libagg' could not
                            be found. Using local copy.]
                  freetype: no  [The C/C++ header for freetype2 (ft2build.h)
                            could not be found.  You may need to install the
                            development package.]
                       png: yes [version 1.6.18]
                     qhull: yes [pkg-config information for 'qhull' could not be
                            found. Using local copy.]

    OPTIONAL SUBPACKAGES
               sample_data: yes [installing]
                  toolkits: yes [installing]
                     tests: yes [nose 0.11.1 or later is required to run the
                            matplotlib test suite. "setup.py test" will
                            automatically download it. Install nose 0.11.1 or
                            later to run matplotlib.test() / using
                            unittest.mock]
            toolkits_tests: yes [nose 0.11.1 or later is required to run the
                            matplotlib test suite. "setup.py test" will
                            automatically download it. Install nose 0.11.1 or
                            later to run matplotlib.test() / using
                            unittest.mock]

    OPTIONAL BACKEND EXTENSIONS
                    macosx: no  [Mac OS-X only]
                    qt5agg: no  [PyQt5 not found]
                    qt4agg: no  [PySide not found; PyQt4 not found]
                   gtk3agg: no  [Requires pygobject to be installed.]
                 gtk3cairo: no  [Requires cairocffi or pycairo to be installed.]
                    gtkagg: no  [Requires pygtk]
                     tkagg: no  [TKAgg requires Tkinter.]
                     wxagg: no  [requires wxPython]
                       gtk: no  [Requires pygtk]
                       agg: yes [installing]
                     cairo: no  [cairocffi or pycairo not found]
                 windowing: no  [Microsoft Windows only]

    OPTIONAL LATEX DEPENDENCIES
                    dvipng: no
               ghostscript: no
                     latex: no
                   pdftops: no

    OPTIONAL PACKAGE DATA
                      dlls: no  [skipping due to configuration]

    ============================================================================
                            * The following required packages can not be built:
                            * freetype

    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-74bls8kw/matplotlib

两行引起了我的注意:

pkg-config is not installed.

但是我无法安装,而且我不知道它到底是什么

freetype: no

已经安装,如下面的日志中所示,但错误仍然存​​在

freebsd@paratudo:~/anythingCollector % sudo pkg install freetype
Updating FreeBSD repository catalogue...
FreeBSD repository is up-to-date.
All repositories are up-to-date.
Checking integrity... done (0 conflicting)
The most recent version of packages are already installed

如何解决这个问题,安装matplotlib?

最佳答案

我的 friend 帮我解决了这个问题:

pkg install pkgconf

我正在搜索 pkgconfig,但在存储库中名称是 pkgconf

关于python-3.x - 在 FreeBSD 上使用 pip3 安装 matplotlib 失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33930191/

相关文章:

python - 列表理解 - 连接每个子列表中的第 n 个项目

python - Pandas Groupby 的排序和绘图输出

python - 如何在没有 root 访问权限的情况下安装 python 模块?

python - 检查我的 Python 是否具有所有必需的包

python-3.x - 如何在 Mac OS X Big Sur 上安装 Python 3.9 的 pandas 模块?

python - Django 不匹配 url 中的 unicode

python - 如何将 "textbox"中的文本添加到图像中?

python - 在python中添加分隔符

python - 将 2x2 DataFrame 整理成 4x1 系列 (Pandas)

python - Matplotlib Python