[Pythonmac-SIG] Matplotlib, other libs and the Universal Python

Charlie Moad cwmoad at gmail.com
Sat Jul 15 03:08:09 CEST 2006


On 7/14/06, Christopher Barker <Chris.Barker at noaa.gov> wrote:
> Hi all,
>
> I'm working on Building a Matplotlib that will work with the Universal
> Python.
>
> I was going along just fine, following the procedure that I've used
> before, but low and behold, I've run into a problem.
>
> MPL Requires libpng and a version of libfreetype that doesn't come with
> OS-X.
>
> In the past, I built static versions of these, put them in a place where
> distutils will find them, and presto!
>
> However, I have a PPC Mac, so I now have PPC libs, and that's won't link
> with the Intel binaries. At least that's what I think the problem is. In
> any case, I know that will be a problem.
>
> So, while I dig around the net for ways to build a universal static libs
> from libpng and libfreetype, does anyone have any hints for me?
>
> Of ready to go packages of these?

Hey Chris,
     I built fat versions of matplotlib-0.87.3 that are on the
sourceforge download page.  I statically linked in png and freetype
and I did all this on a ppc machine.  It is really easy to build these
dependency libs.  Just make sure, "-arch ppc -arch i386" is in you
CFLAGS.  This will cause everything to be built fat.
    I haven't got around to the 0.87.4 mac builds yet.  I can assure
you it is very similar to just building for ppc though.  The universal
build of python adds those compiler flags for you, so you don't need
to worry about them when using distutils.  Let me know if you want any
help.

- Charlie


More information about the Pythonmac-SIG mailing list