2012-04-11 17 views
0

Ich benutze derzeit Matplotlib 1.0.1, läuft mit Python 2.7.1, aber ich möchte es auf mindestens 1.1.0 zu aktualisieren. Allerdings, wenn ich versuche, matplotlib-1.1.0-py2.7-python.org-macosx10.3.dmg voneasy_install matplotlib Updates auf Mac OS X

http://sourceforge.net/projects/matplotlib/files/matplotlib/,

den nachfolgenden Installationsstatus „matplotlib 1.1.0 Download kann nicht installiert werden Auf dieser Festplatte muss matplotlib System Python 2.7 installieren. "

Alternativ habe ich versucht, in das Terminal $ easy_install matplotlib und bekam die folgende Ausgabe:

install_dir /Library/Frameworks/Python.framework/Versions/7.0/lib/python2.7/site-packages/ Searching for matplotlib Best match: matplotlib 1.0.1 Adding matplotlib 1.0.1 to easy-install.pth file

Using /Library/Frameworks/Python.framework/Versions/7.0/lib/python2.7/site-packages Processing dependencies for matplotlib Finished processing dependencies for matplotlib

Und matplotlib Upgrade $ easy_install die folgenden Fehler wurde:

BUILDING MATPLOTLIB matplotlib: 1.1.0 python: 2.7.1 |EPD 7.0-2 (32-bit)| (r271:86832, Dec 3 2010, 15:41:32) [GCC 4.0.1 (Apple Inc. build 5488)] platform: darwin

REQUIRED DEPENDENCIES numpy: 1.5.1 freetype2: found, but unknown version (no pkg-config) * WARNING: Could not find 'freetype2' headers in any * of '.', './freetype2'.

OPTIONAL BACKEND DEPENDENCIES libpng: found, but unknown version (no pkg-config) * Could not find 'libpng' headers in any of '.' Tkinter: Tkinter: 81008, Tk: 8.4, Tcl: 8.4 Gtk+: no * Building for Gtk+ requires pygtk; you must be able * to "import gtk" in your build/install environment Mac OS X native: yes Qt: no Qt4: no Cairo: no

OPTIONAL DATE/TIMEZONE DEPENDENCIES datetime: present, version unknown dateutil: 1.5 pytz: 2010o

OPTIONAL USETEX DEPENDENCIES dvipng: 1.13 ghostscript: 8.71 latex: 3.1415926

[Edit setup.cfg to suppress the above messages] ============================================================================ 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'] 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' In file included from src/ft2font.h:16, from src/ft2font.cpp:3: /Library/Frameworks/Python.framework/Versions/7.0/include/ft2build.h:56:38: error: freetype/config/ftheader.h: No such file or directory In file included from src/ft2font.cpp:3: src/ft2font.h:17:10: error: #include expects "FILENAME" or src/ft2font.h:18:10: error: #include expects "FILENAME" or src/ft2font.h:19:10: error: #include expects "FILENAME" or src/ft2font.h:20:10: error: #include expects "FILENAME" or src/ft2font.h:21:10: error: #include expects "FILENAME" or In file included from src/ft2font.cpp:3: src/ft2font.h:35: error: ‘FT_Bitmap’ has not been declared src/ft2font.h:35: error: ‘FT_Int’ has not been declared src/ft2font.h:35: error: ‘FT_Int’ has not been declared src/ft2font.h:91: error: expected ‘,’ or ‘...’ before ‘&’ token src/ft2font.h:91: error: ISO C++ forbids declaration of ‘FT_Face’ with no type src/ft2font.h:138: error: ‘FT_Face’ does not name a type src/ft2font.h:139: error: ‘FT_Matrix’ does not name a type src/ft2font.h:140: error: ‘FT_Vector’ does not name a type src/ft2font.h:141: error: ‘FT_Error’ does not name a type src/ft2font.h:142: error: ‘FT_Glyph’ was not declared in this scope src/ft2font.h:142: error: template argument 1 is invalid src/ft2font.h:142: error: template argument 2 is invalid src/ft2font.h:143: error: ‘FT_Vector’ was not declared in this scope src/ft2font.h:143: error: template argument 1 is invalid src/ft2font.h:143: error: template argument 2 is invalid src/ft2font.h:149: error: ‘FT_BBox’ does not name a type src/ft2font.cpp:51: error: ‘FT_Library’ does not name a type src/ft2font.cpp:114: error: variable or field ‘draw_bitmap’ declared void src/ft2font.cpp:114: error: ‘FT_Bitmap’ was not declared in this scope src/ft2font.cpp:114: error: ‘bitmap’ was not declared in this scope src/ft2font.cpp:115: error: ‘FT_Int’ was not declared in this scope src/ft2font.cpp:116: error: ‘FT_Int’ was not declared in this scope error: Setup script exited with error: command 'gcc' failed with exit status 1

Sorry, wenn dieses Problem auch ist elementar, aber ich kann einfach nicht herausfinden, wo der Fehler sein könnte. Danke für Ihre Hilfe!

+1

Obwohl Sie einen Paketmanager wie MacPorts oder homebrew verwenden können, um matplotlib unter OS X zu installieren, sollten Sie meine Antwort auf eine verwandte Frage [hier] lesen, wenn Sie an einer Methode interessiert sind, die nur die von XCode bereitgestellten freetype- und libpng-Bibliotheken verwendet. (http://stackoverflow.com/a/10843478/781673). – mhowison

Antwort

0

Wenn Sie x64 OS X-Version (Snow Leopard oder Lion) verwenden nur this one herunterladen.

+0

Bekam die gleiche Fehlermeldung wie zuvor. –

+0

Fehlermeldung enthält: "Konnte Header 'libpng' nicht in '.'" Finden. Aktualisieren Sie libpng mit easy_install, bevor Sie matplotlib aktualisieren. – SkyFox

+0

Es wurde aktualisiert, erhielt aber genau die gleichen Fehlermeldungen, sogar die, die Sie angaben. –