Matplotlib-devel Digest, Vol 39, Issue 22

Thanks for the suggestion Jeff. I have been dealing with the same problem. I found the makefile in
from an EPD install. Is this makefile the template used whenever I build a package against python using distutils? Or do I need to rebuild python somehow for i386 only?



---------- Forwarded message ----------

From: Jeff Whitaker <jswhit@…752…>

To: Michael Hearne <mhearne@…753…1…>
Date: Wed, 12 Aug 2009 13:42:07 -0600
Subject: Re: [matplotlib-devel] Building matplotlib on os x
Michael Hearne wrote:

I apologize for cross-posting - I realized I probably shouldn’t have posted this on the user’s list first…

Hello - I am attempting to build matplotlib from source on os X, and getting an error about a shared library being the wrong architecture. The confusing thing is that the call to g++ has two settings for arch:

“g++ -arch i386 -arch ppc…”

The error I get is:

“ld: in /Developer/SDKs/MacOSX10.4u.sdk/Library/Frameworks/ Python.framework/Versions/4.3.0/lib/libz.1.dylib, file is not of required architecture for architecture ppc”

Is there some way to turn off the “-arch ppc” option to g++ in Or do I have some other problem?

Build output is included below.



Mike: You need to edit


(or whatever the corresponding path is for your python installation)

and remove all references to “-arch ppc” if you don’t want to build universal binaries (which you can’t if the libs you’re linking are not universal).


Jeffrey S. Whitaker Phone : (303)497-6313

Meteorologist FAX : (303)497-6449

NOAA/OAR/PSD R/PSD1 Email : Jeffrey.S.Whitaker@…236…

325 Broadway Office : Skaggs Research Cntr 1D-113

Boulder, CO, USA 80303-3328 Web :