2013-10-31 24 views
2

安装我在Oracle VirtualBox的我的Windows 7机器上运行Fedora Linux系统/ RHEL,并试图在虚拟机上安装matplotlib-1.3.1。 我有numpy-1.6.1,scipy-0.13.0以及python-2.6.6。NumPy的Matplotlib在Fedora Linux系统

都与NumPy和SciPy的是从源头即内置下载的tar.gz文件,提取,然后跑了建立和从提取的文件夹中安装。我也检查了从python shell安装的版本。

但是,每当我试图从源代码编译matplotlib-1.3.1,它给我下面的屏幕。

下面是屏幕从源代码构建matplotlib时:

~]$ python setup.py build 
============================================================================ 
Edit setup.cfg to change the build options 

BUILDING MATPLOTLIB 
     matplotlib: yes [1.3.1] 
      python: yes [2.6.6 (r266:84292, Jul 10 2013, 22:48:45) [GCC 
        4.4.7 20120313 (Red Hat 4.4.7-3)]] 
      platform: yes [linux2] 

REQUIRED DEPENDENCIES AND EXTENSIONS 
      numpy: yes [version 1.6.1] 
      dateutil: yes [using dateutil version 2.1] 
      tornado: yes [tornado was not found. It is required for the 
        WebAgg backend. pip/easy_install may attempt to 
        install it after matplotlib.] 
     pyparsing: yes [pyparsing was not found. It is required for 
        mathtext support. pip/easy_install may attempt to 
        install it after matplotlib.] 
      pycxx: yes [Couldn't import. Using local copy.] 
      libagg: yes [pkg-config information for 'libagg' could not 
        be found. Using local copy.] 
      freetype: no [pkg-config information for 'freetype2' could 
        not be found.] 
       png: yes [version 1.2.49] 

OPTIONAL SUBPACKAGES 
     sample_data: yes [installing] 
      toolkits: yes [installing] 
      tests: yes [using nose version 1.3.0] 

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

OPTIONAL LATEX DEPENDENCIES 
      dvipng: no 
     ghostscript: yes [version 8.70] 
      latex: no 
      pdftops: no 

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

我试图建立依赖关系matplotlib为Matplotlib install page提及,但我得到的消息,“没有源RPM发现”,如下图所示:

~]$ su -c "yum-builddep python-matplotlib" 
Password: 
Loaded plugins: fastestmirror, priorities 
Loading mirror speeds from cached hostfile 
* HDP-epel: mirror.us.leaseweb.net 
* base: mirror.dattobackup.com 
* epel: mirror.us.leaseweb.net 
* extras: centos.aol.com 
* updates: mirror.cogentco.com 
59 packages excluded due to repository priority protections 
Checking for new repos for mirrors 
Enabling epel-source repository 
epel-source/metalink             | 14 kB  00:00 
epel-source               | 3.3 kB  00:00 
http://mirror.umd.edu/fedora/epel/6/SRPMS/repodata/repomd.xml: [Errno -1] repomd.xm does not match metalink for epel-source 
Trying other mirror. 
epel-source               | 3.5 kB  00:00 
epel-source/primary_db            | 1.6 MB  00:01 
9 packages excluded due to repository priority protections 
No source RPM found for python-matplotlib-0.99.1.2-1.el6.x86_64 
No uninstalled build requires 

只是要注意,我已经成功地从源鼻1.3.0,IPython中-1.1.0,sympy-0.7.3,熊猫-0.11.0建成安装matplotlib之前的依赖性。

回答

0

上述问题得以解决。这是因为无法找到所需的freetype软件包。

有兴趣的读者可以去链接

Freetype-2.5.0 Install

,并按照得到FreeType的安装步骤。请注意,解压缩bz2文件后,必须进入该文件夹才能运行./configure和make。要安装文档,需要以root用户身份登录并按照上述命令进行操作。希望这可以帮助。

注:我已经越来越得到解决,但有一个新的错误没有发现ftheader.h的时引发上述错误。我为此打开了一个单独的线程。这里是链接

Install error: ftheader.h: No such file or directory