Issue39

Title Python's distutils is lying/broken
Priority bug Status chatting
Superseder Nosy List leif
Assigned To leif Topics Build

Created on 2006-06-17.00:58:11 by leif, last changed 2008-10-07.00:21:19 by leif.

Messages
msg500 (view) Author: leif Date: 2008-10-07.00:21:19
Charles just tried out the Enthought Python Distribution, which has a new and
different type of garbage:

PYTHON_LDLIBRARY = Python.framework/Versions/2.5.2001/Python

This trips up CIT_PYTHON_SYSCONFIG, which isn't expecting the ".2001".

There is a new wrinkle:  I just noticed that both our Macs have
/usr/lib/libpython2.3.dylib -- which, in turn, depends upon the framework.  This
leads me to believe that the simplistic code in the 'python2.x-config' utility
is the right way to do things.  Maybe one can pretend frameworks don't exist on
Mac OS X, and just use -lpython2.x.
msg273 (view) Author: leif Date: 2007-01-31.15:46:09
Resolved: fixed on Cygwin (for both Cygwin Python and Python for Windows).

r5941 (cs/autoconf/trunk/cit_python.m4)
msg169 (view) Author: leif Date: 2006-11-16.13:12:51
Fixed on Mac OS X.  (The Cygwin issue remains.)

r5301 (cs/autoconf/trunk/cit_python_sysconfig.m4)


Distutils seems to lack any facility for relinking the Python intepreter, which
means it is impossible to do embedding portably.  The fix above is another
special-case hack in a growing if-then-else ladder of such hacks.

Note that there is a third dicey platform: AIX.
msg86 (view) Author: leif Date: 2006-06-17.03:06:22
On both platorms, try creating an extension module using pure distutils... if
that works, then clearly it knows something that my Autoconf macros don't.
msg85 (view) Author: leif Date: 2006-06-17.03:05:22
This also doesn't work on Cygwin. "libpython2.4.dll.a" is nested inside Python's
'config' directory, where the linker can't find it.
msg84 (view) Author: leif Date: 2006-06-17.00:58:11
I saw this before on Gurnis' Mac, and now it reproduces on my Mini... because I
upgraded to Tiger (?)

g++-3.3: Python.framework/Versions/2.3/Python: No such file or directory
m

PYTHON_LDLIBRARY is clearly broken: it's supposed to be "-framework Python" or
something.  But somehow I don't think it's my fault.  Is distutils broken on
Mac?  Whatever the case, need fix/work-around.
History
Date User Action Args
2008-10-07 00:21:19leifsetstatus: resolved -> chatting
messages: + msg500
2007-01-31 15:46:09leifsetstatus: chatting -> resolved
messages: + msg273
2006-11-16 13:12:51leifsetmessages: + msg169
2006-06-17 03:06:22leifsetmessages: + msg86
2006-06-17 03:05:22leifsetstatus: unread -> chatting
messages: + msg85
title: Mac Python's distutils is lying -> Python's distutils is lying/broken
2006-06-17 00:58:11leifcreate