[Pythonmac-SIG] python 2.3.4 on Mac OS X 10.3.6 is working - upgraded standard installation

Bob Ippolito bob at redivi.com
Wed Dec 1 14:20:32 CET 2004


On Dec 1, 2004, at 3:47 AM, Robert Kern wrote:

> Bob Ippolito wrote:
>
>> Once you know where this Makefile is, open it up with your favorite 
>> text editor (probably using sudo).
>> Navigate to approximately line 98 and replace the two configuration 
>> variables LDSHARED and BLDSHARED with the following:
>> LDSHARED=   env MACOSX_DEPLOYMENT_TARGET=10.3 $(CC) $(LDFLAGS) 
>> -bundle -undefined dynamic_lookup
>> BLDSHARED=  env MACOSX_DEPLOYMENT_TARGET=10.3 $(CC) $(LDFLAGS) 
>> -bundle -undefined dynamic_lookup
>
> This is problematic for extensions that need to use something other 
> than $(CC) to link, specifically C++ and FORTRAN extensions. distutils 
> (and scipy_distutils in the FORTRAN case) splits $LDSHARED on 
> whitespace and substitutes the appropriate tool into the first index. 
> Thus you end up with distutils trying to run commands like
>
>   c++ MACOSX_DEPLOYMENT_TARGET=10.3 gcc ... etc.

Well, that's just stupid!  One of two things need to happen:
- distutils and scipy_distutils need to be fixed to be able to mangle 
environment variables before invoking the toolchain
- distutils and scipy_distutils need to do something reasonable 
instead, like replace the $(CC) variable before substitution, not the 
first word it sees after substitution.

This may be an issue for 10.4 though, as the public sources in the WWDC 
build were a slightly modified 2.3.3 that used this style LDSHARED.  I 
guess the solution in this case is to backport both patches back to 
2.3.4 and get a 2.3.5 release cut, which Apple would hopefully pick up 
if enough bug reports are filed and emails sent :)

-bob



More information about the Pythonmac-SIG mailing list