Ned Deily added the comment:

Since I just noticed this and haven't seen it mentioned already: for the 
record, the Python Makefile for current versions is affected by this issue.  
The "sharedmods" target, which calls setup.py to build the standard library 
shared modules, explicitly passes into Distutils via shell variables values for 
CC, LDSHARED, and OPT.  Unfortunately, as noted in this issue, Distutils does 
not look for an OPT variable.  So, while CC and LDSHARED can be overridden from 
the make command with either macro arguments or env vars, OPT cannot: only the 
value determined at configure time will be used.

I think that Chris's original distutils_opt_flag.patch should be applied to 
allow OPT to be overridden, without changing any other current behavior.  
AFAICT, the only compatibility issue would be if a script happened to already 
have an OPT env variable defined which would now get used by Distutils. I think 
the risks of that are pretty small and, in case, much smaller than the more 
extensive tweaking of Distutils behavior as is done in the Debian patches.

My interest in this comes from discovering that the OS X installer build script 
has been overriding OPT for its own purposes, thereby inadvertently dropping 
compiler options determined by configure (things like -fwrapv) which can result 
in a broken interpreter.  I've changed the installer build to no longer do 
that.  But that does mean that users of the OS X installer will now see those 
missing compiler options during extension module builds and it is conceivable 
that could cause problems for some ext modules and there wouldn't be a simple 
way to work around them (e.g. by setting an OPT env value).  If no one has any 
strong objections, I'll plan to commit that patch soon.

----------
components:  -Distutils2
nosy: +ned.deily
versions:  -3rd party, Python 3.1, Python 3.2

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue969718>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to