Matplotlib install failure on Mac OSX 10.8 Mountain Lion

前端 未结 11 1044
眼角桃花
眼角桃花 2020-12-23 02:21

I tried to install matplotlib on my MacBook Air, but it always gives me this error message:

 Processing matplotlib-1.1.1_notests.tar.gz
 Running matplotlib-1         


        
11条回答
  •  悲&欢浪女
    2020-12-23 02:55

    This may help folks looking for a non-homebrew solution.

    My goal: use pip install to build matplotlib for a non-system python 2.7.3 build.

    Using latest X-Code and X-Code command line tools as of Feb 2013, no matter what gymnastics I tried, I always received C++ ostream related template errors when compiling ft2build with gcc.

    I was able to get a pip install to work with the following env vars:

    export CC=clang
    export CXX=clang++
    export LDFLAGS="-L/usr/X11/lib"
    export CFLAGS="-I/usr/X11/include -I/usr/X11/include/freetype2"
    

    I simply forced clang and added my xquartz paths. No extra pkg-config or libpng builds, no sudo-ed symlinks.

提交回复
热议问题