[Pythonmac-SIG] Re: Embedding Python on OS X, nem to the list

Russell E. Owen rowen at cesmail.net
Tue Dec 23 13:50:32 EST 2003


In article <DDC4A855-3530-11D8-AB1C-000393449862 at post.rwth-aachen.de>,
 Mark Asbach <mark.asbach at post.rwth-aachen.de> wrote:

> Hi list,
> 
> first off, I'm new to this list, so here's my background: At the 
> moment, I'm doing my diploma thesis on visualization of finite element 
> data in the electric engineering department at Aachen university. This 
> is also where I came into contact with Python, because the software 
> package developed at the institute uses an embedded Python interpreter...

I can only answer the last question:

> - What will I need to do to get a working Tcl/Tk setup?

It depends if you want an aqua interface (native MacOS look and feel) or 
unix X11.
- Aqua Tk is very easy to install, but has some annoying cosmetic bugs. 
Also Python 2.3 itself has some bugs (including some standard tk file 
dialogs are broken) and on Panther you are stuck with it if you want 
aqua.

- X11 is less mac-like but a bit more solid. Also, you can install a 
current version of Python. It is fairly easy to install from fink or 
source, but takes awhile.

To install aqua Python and Tkinter:
- Install Tcl/Tk from one of the aqua binary installers available from 
<http://www.maths.mq.edu.au/~steffen/tcltk/TclTkAqua/>.
- Download the MacPython binary for Panther or Jaguar (as appropriate) 
at the MacPython web site <http://homepages.cwi.nl/~jack/macpython/> and 
run that.
- Run the Package Manager (in /Applications/MacPython). If you keep your 
OS up to date, the package manager may not find the required URL, in 
which case see <http://www.python.org/packman>.
- Use Package Manager to nstall _tkinter and anything else of interest.


To install X11 Python and Tkinter:
You can install everything (including python) from fink (a package 
manager for MacOS X; try google) or from source. Here are instructions 
from source:

Install X11 and the X11 SDK first (there are other options, not 
discussed here). For Jaguar, you can download installers from apple. For 
Panther, X11 is an *optional* extra installation of the main operating 
system, so pay attention when you start your install (or perhaps 
Pacifist will let you get to it on the install CD). X11 SDK is part of 
the developer tools. 

It is helpful to install readlines. To install readlines 4.3, obtain the 
source and edit .../readlines-4.3/support/shobj-conf to change line 151 
from: 
     SHLIB_LIBS='-lSystem'
to: 
     SHLIB_LIBS='-lSystem -lncurses -lcc_dynamic'
and then do the normal ./configure; make; sudo make install sequence.

Install tcl/tk from source following the normal unix instructions.

Install python from source, following the normal unix instructions.

-- Russell




More information about the Pythonmac-SIG mailing list