[Pythonmac-SIG] SIOUX Console ( was sys.exit )

Jack Jansen jack@oratrix.com
Fri, 1 Feb 2002 15:05:32 +0100


On Thursday, January 31, 2002, at 11:37 , Alexandre Parenteau wrote:

> Jack,
>
>> On Wednesday, January 30, 2002, at 06:42  PM, Alexandre Parenteau 
>> wrote:
>>> [unrelated] Jack, I understand why you put it inside #ifdef
>>> USE_GUSI2 but it
>>> forces us to have the GUSI2 header externally, whereas in
>>> theory we would
>>> not have to use GUSI in order to use for the Python SDK.
>>
>> You'll have to explain what you mean here, "forces us to have
>> the GUSI2 header externally".
>
> Let say I want to use MacPython embedded in an application Y. When I 
> compile
> Y, I don't have necessarily to use GUSI 1 or 2. I can use MSL instead or
> anything else (it is not completely true because if I end-up using 
> another
> C-library for Y, I may not be able to pass a FILE object to Python).

This is very dangerous. You must make absolutely sure that MSL is linked 
before PythonCore, and that there's no way your hosting program can ever 
satisfy a reference to an external from the GUSI-enabled MSL in 
PythonCore, or very bad things will happen.

>>> [unrelated] About a SDK, I regret we don't have PEF stub library and a
>>> dedicated folder that we could copy at once to write
>>> components. Something
>>> like Python2.2/SDF/Headers, Python2.2/SDF/Headers/Mac,
>>> Python2.2/SDF/Libraries, Python2.2/SDF/Resources.
>>
>> Again, you have to explain, I understand neither what you're
>> trying to accomplish, nor how:-)
>
> I try to still embed MacPython in the application Y. I like to embed, 
> it's
> me... :-)
>
> I'd like to have a MacPython SDK folder. If I'm interested only in 
> making
> compiled components to Python, it is handy to get the minimal set of 
> Headers
> and Libraries for doing so. Having a stub library is part of the "nice"
> thing.

If I understand this correctly the only thing needed, aside from what is 
installed by the "developer" option in the installer already, is a 
PythonCore.lib stub library, right? That should be reasonably simple: an 
extra "stub library" project in PythonCore.prj should do the trick.

An advantage of this might be that we could possibly also create a 
PythonCoreNoMSL.lib stub library which is the same stub library but with 
all MSL symbols removed. This would make life easier for the case where 
you want to embed Python into a non-GUSI application.
--
- Jack Jansen        <Jack.Jansen@oratrix.com>        
http://www.cwi.nl/~jack -
- If I can't dance I don't want to be part of your revolution -- Emma 
Goldman -