sec6 wrote:
> 
> sent to:  matplotlib-users@lists.sourceforge.net
> 
> I'm attempting to install matplotlib under version 10.5 ("Leopard") of  
> the Macintosh operating system.
> 
> I had an old installation, via Fink, which broke when I (foolishly)  
> upgraded from version 10.4 to version 10.5.
> 
> In principle, installing matplotlib under 10.5 should be simple,  
> because Leopard already includes all of matplotlib's dependencies:
>       Python 2.4 (and 2.5)
>       numpy
>       libpng
>       zlib
>       freetype
>       
> In practice, I seem to be running into trouble with freetype.
> 
> ...snip...
> 
> I am going to try some monkey business along the lines of
>       ln /usr/X11/lib/libfreetype.6.dylib /sw/lib/freetype219/lib/ 
> libfreetype.6.dylib
> and will let you know the results.  However, even if that works, it's  
> a heinous kluge, and probably fragile, too.
> 
> 

Jed's solution (bootstrap Fink from scratch) didn't work for me (Bootstrap
worked OK, but installing matplotlib  failed with "Could not resolve
inconsistent dependencies!")

However, I have now tried the "monkey business" alluded to above, and it was
successful.
#Start by launching XWindows. now:
        cd /sw/lib/freetype219/lib
        sudo ln -s /usr/X11/lib/libfreetype.6.dylib ./libfreetype.6.dylib
        <...enters password...>
        cd ~
        pythonw2.5
        >>> import pylab
#Bingo!  no error.
        >>> fig = pylab.figure()
#Empty window appears on screen.
        >>> pylab.plot([1,2,3],[1,2,3])
        [<matplotlib.lines.Line2D instance at 0x163e558>]
#Correct plot appears in window
        >>> fig.savefig('/Users/username/Desktop/temp.ps')
#Open temp.ps in a graphics program (Canvas, as it happens). Looks good.

Using pythonw, rather than python, is important.
With pythonw, pylab.figure() displays the figure, whereas with plain python,
the figure doesn't display untill you do pylab.show().
Also, with plain python, you don't get the ">>>" prompt back 'till you close
the figure window, whereas with pythonw you get it back as soon as the
figure's displayed.
That last is important to me, because it replicates the (to me) single moust
useful thing about ipython. That means I *don't* need to install ipython,
now.

I still hope somebody more expert will discover a less ugly, more general,
and less fragile solution.



-- 
View this message in context: 
http://www.nabble.com/Installing-under-Leopard-%28Mac-OSX-10.5%29-tf4798891.html#a13777470
Sent from the matplotlib - users mailing list archive at Nabble.com.


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to