2014-08-31 2 views
14

저는 우분투 14.04를 사용 중이며 pip를 사용하여 matplotlib를 설치하려고합니다. 파이썬 2.7.6을 사용하고 있습니다. 내가 실행할 때마다 그러나, "sudo는 PIP 것은하기 matplotlib를 설치", 나는 다음과 같은 오류를 얻을 : 나는 "필요한 종속성 및 확장"에 나열된 모든 종속성을 설치 시도했습니다,하지만 난 여전히 같은 오류가pip를 사용하여 matplotlib을 설치할 수 없습니다.

Downloading/unpacking matplotlib 
Downloading matplotlib-1.4.0.tar.gz (51.2MB): 51.2MB downloaded 
Running setup.py (path:/tmp/pip_build_root/matplotlib/setup.py) egg_info for package matplotlib 
    ============================================================================ 
    Edit setup.cfg to change the build options 

    BUILDING MATPLOTLIB 
      matplotlib: yes [1.4.0] 
       python: yes [2.7.6 (default, Mar 22 2014, 22:59:56) [GCC 
         4.8.2]] 
       platform: yes [linux2] 

REQUIRED DEPENDENCIES AND EXTENSIONS 
       numpy: yes [version 1.8.1] 
        six: yes [using six version 1.5.2] 
       dateutil: yes [using dateutil version 2.2] 
       tornado: yes [using tornado version 4.0.1] 
      pyparsing: yes [using pyparsing version 2.0.2] 
       pycxx: yes [Couldn't import. Using local copy.] 
       libagg: yes [pkg-config information for 'libagg' could not 
         be found. Using local copy.] 
Traceback (most recent call last): 
    File "<string>", line 17, in <module> 
    File "/tmp/pip_build_root/matplotlib/setup.py", line 154, in <module> 
    result = package.check() 
    File "setupext.py", line 940, in check 
    if 'No such file or directory\ngrep:' in version: 
TypeError: argument of type 'NoneType' is not iterable 
Complete output from command python setup.py egg_info: 
============================================================================ 

Edit setup.cfg to change the build options 

.

+0

libagg를 설치해야하는 것처럼 보입니다 –

+0

libagg-dev 패키지가 설치되었으며 libagg 메시지가 "libagg : yes [로컬 복사본을 사용하여 업스트림 병합되지 않은 패치가 필요합니다]"로 변경되었습니다. – mp94

답변

12

동일한 오류 메시지가 표시되고이 게시물에 언급 된 종속성을 설치하면 Pip install Matplotlib error with virtualenv이 나를 위해이 문제를 해결했습니다.

+7

3 가지 설치 패키지'libjpeg8-dev','libfreetype6-dev','libpng12-dev'가 작동했습니다! (나는 이미 freetype과 png 패키지를 설치했다.) 또한 원래 게시물에 대한 주석에서 권장하는대로'libagg-dev'를 설치했다. – mp94

+5

sudo apt-get build-dep matplotlib가 우분투에서 작동했습니다. 14.04 –

+3

Mac :'brew install freetype' –

관련 문제