Arfrever Frehtes Taifersar Arahesis added the comment:

OPT should not be used in Distutils at all.

Lib/distutils/sysconfig.py should have:
    if 'CFLAGS' in os.environ:
        cflags = os.environ['CFLAGS']

Makefile.pre.in should have:
    $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' CFLAGS='$(PY_CFLAGS)' \
    _TCLTK_INCLUDES='$(TCLTK_INCLUDES)' _TCLTK_LIBS='$(TCLTK_LIBS)' \
    $(PYTHON_FOR_BUILD) $(srcdir)/setup.py $$quiet build

PY_CFLAGS is defined as:
PY_CFLAGS=      $(BASECFLAGS) $(OPT) $(CONFIGURE_CFLAGS) $(CFLAGS) 
$(EXTRA_CFLAGS)

So then OPT could be overriden when calling `make`.

See my patch for Distutils in bug #1222585. That patch also cleans handling of 
flags.

----------

_______________________________________
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