This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ned.deily
Recipients barry, ned.deily, ronaldoussoren
Date 2009-09-26.09:29:32
SpamBayes Score 5.55112e-17
Marked as misclassified No
Message-id <1253957377.74.0.0869633575494.issue6957@psf.upfronthosting.co.za>
In-reply-to
Content
Explicitly defining CC during the installer build does seem to fix the 
extension build problem, at least for well-behaved extensions.  I 
successfully tested building simplejson (using both easy_install and 
direct setup.py installs) and MySQLdb, both on 10.6 using a fat 
installer built on 10.5 with DEPTARGET=10.3 and 10.4u SDK, test cases 
that previously failed.

I've attached a patch to build-installer.py to support setting CC to 
appropriate values for distutils based on the value of deployment 
target: gcc-4.0 for DEPTARGET in [10.3, 10.4, 10.5], gcc-4.2 for 10.6.

The patch also includes changes to the build process itself to use the 
appropriate gcc, including the recipes for the 3rd-party libs.  This is 
in support of building installers on 10.6 with gcc-4.0 and 10.4u SDKs 
(however, there are still problems with this - see below).

It also includes fixes for two unrelated build problems noted during 
testing: (1) the doc html files are installed in the wrong location in 
the framework (this was fixed in 3.x but not yet backported); and (2) 
the recently changed test for 10.4 or later was off by one (causing 
building to fail on 10.4 systems).  Those fixes should go into 2.6.3 
regardless.

There are some open issues with the patch:

1. Should CXX (the distutils environ value for the c++ compiler) also be 
set? There are multiple paths through configure involving CC and CXX.

2. I chose not to implement a --cc argument to build-installer.py 
figuring it would be safer to hard code the appropriate CC values into 
the script for the time being.

3. While the script as is does not cause regressions for installer 
builds on 10.5 or 10.4 (that is, assuming the remaining builds and tests 
in progress complete normally - I'll update the status when they 
finish), as it stands I am still not able to build "standard" fat 
installers using the 10.4u SDK on 10.6.  There seem to be problems up 
front in configure: a number of build options are coming out differently 
when using 10.4u on 10.6 than on 10.5, presumably causing the cc compile 
errors.  It's not a release-blocker problem, anyway, since the plan is 
to build the installer on 10.5 but we do need to get a better idea 
what's going wrong there.  (Unfortunately, I don't expect to have time 
to investigate this further prior to the 2.6.3 release.)
History
Date User Action Args
2009-09-26 09:29:38ned.deilysetrecipients: + ned.deily, barry, ronaldoussoren
2009-09-26 09:29:37ned.deilysetmessageid: <1253957377.74.0.0869633575494.issue6957@psf.upfronthosting.co.za>
2009-09-26 09:29:36ned.deilylinkissue6957 messages
2009-09-26 09:29:34ned.deilycreate