★ wanayoo — archive 1999 http://mail.python.org/pipermail/pythonmac-sig/2002-April/005491.htmlNouvelle recherche | Portail wanayoo

[Pythonmac-SIG] Python defaulting as a framework for OSX/Mach-O

Alexandre Parenteau aparente@adobe.com
Thu, 18 Apr 2002 12:11:02 -0700


Folks,

The primary reason of my email is to push for defaulting the compilation of
Python-Mach-O as a framework, so application on OSX can embed Python easily.
It would be nice also to provide an installer of Python this way.

In the current MacCvs CVS (cvsgui on SourceForge), I have now a MacCvsX
(Mach-O) loading dynamically Python (Mach-O) to handle the Macros of
MacCvsX. Previously the same thing was working in CFM with MacCvs (CFM) and
MacPython (CFM).

The step is important for me : I can check-out Python code using OpenSSH,
with Unix line feed, ISO text encoding, cvs-MachO spawned by MacCvsX. All is
now functional under Mach-O. I can compile the Mach-O and CFM Python with
the same sandbox (one using gcc, the other one CodeWarrior), which is even
better. So except for CodeWarrior, I never quit Mach-O for the whole
process.

[I guess some still wonder why I want so much to use Mach-O and not CFM,
that is because under CFM you don't have a good PosIX layer, only an
emulation named "GUSI"]

But using Mach-O/OSX you are more or less required to use the Frameworks
mechanism for dynamic loading Python (I didn't find a way to deal with
dlopen, I suspect only .so object can be loaded thru this mechanism).

So what prevent from defaulting to Framework and distributing it this way ?
I guess it has some impacts on distutils. Is that working with Python
installed as a Framework (I never tried ) ?

I wanted also to point out that people who want to embed dynamically Python
in either a Classic, CFM-Carbon, Mach-O-Carbon or Win32 platform can find a
complete example inside the MacCvs/WinCvs source code.

Regards,
Alex.

-- 
Alexandre Parenteau
Computer Scientist
Core Technologies, AGM
Adobe Systems, Inc.
408-536-6166