[Patches] [ python-Patches-1056561 ] python / pythonw replacement in C

SourceForge.net noreply at sourceforge.net
Sat Jul 15 18:32:44 CEST 2006


Patches item #1056561, was opened at 2004-10-29 01:26
Message generated for change (Comment added) made by etrepum
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1056561&group_id=5470

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Macintosh
Group: Python 2.4
>Status: Closed
>Resolution: Duplicate
Priority: 5
Submitted By: Michiel de Hoon (mdehoon)
Assigned to: Jack Jansen (jackjansen)
Summary: python / pythonw replacement in C

Initial Comment:
I rewrote the shell script pythonw2.4 (which usually
lives in /usr/local/bin) in C. With a link from python
to this C program, users can:
a) Run "python" to use the framework version of Python,
which exists in a valid application bundle (unlike the
current python in /usr/local/bin);
b) Use "#!/usr/local/bin/python" as the first line in
python scripts (unlike the current pythonw in
/usr/local/bin, which Mac OS X interprets to be a shell
script).
Hence, (I believe) this C program avoids the problems
with python and pythonw that are in /usr/local/bin now.
The setup in /usr/local/bin would be:

lrwxr-xr-x python -> python2.4
-rwxr-xr-x python2.4

where python2.4 is the C program calling
/Library/Frameworks/Python.framework/Versions/2.4/bin/python
with the appropriate command-line arguments.

Some modification of the C code may be needed for it to
be consistent with the Python installation process.
Note also that for the non-framework build, python2.4
can just be a link (as it is now).

----------------------------------------------------------------------

>Comment By: Bob Ippolito (etrepum)
Date: 2006-07-15 12:32

Message:
Logged In: YES 
user_id=139309

This is a duplicate of http://python.org/sf/1038911

Python 2.5 has similar functionality (but does not descend from this patch)

----------------------------------------------------------------------

Comment By: Michiel de Hoon (mdehoon)
Date: 2004-10-29 01:35

Message:
Logged In: YES 
user_id=488897

I just noticed that Nathan Gray had already submitted a
similar patch (my impression from the pythonmac-sig archive
was that that hadn't happened yet, but I guess I should have
checked existing patches before submitting one). Well I hope
maybe it is still useful for something.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1056561&group_id=5470


More information about the Patches mailing list