Mercurial > hg
comparison setup.py @ 21839:f266be73f764 stable
setup: fixed for Pythons which don't have a CFLAGS
Specifically this is observed to happen on the PyPy one gets from homebrew
author | Alex Gaynor <alex.gaynor@gmail.com> |
---|---|
date | Sat, 05 Jul 2014 07:31:08 -0700 |
parents | 54d7657d7d1e |
children | 0c88185c7d6c |
comparison
equal
deleted
inserted
replaced
21831:2392b9e19366 | 21839:f266be73f764 |
---|---|
532 # C extension modules, and a bug has been filed upstream at | 532 # C extension modules, and a bug has been filed upstream at |
533 # http://bugs.python.org/issue21244. We also need to patch this here | 533 # http://bugs.python.org/issue21244. We also need to patch this here |
534 # so Mercurial can continue to compile in the meantime. | 534 # so Mercurial can continue to compile in the meantime. |
535 if xcode51: | 535 if xcode51: |
536 cflags = get_config_var('CFLAGS') | 536 cflags = get_config_var('CFLAGS') |
537 if re.search(r'-mno-fused-madd\b', cflags) is not None: | 537 if cflags and re.search(r'-mno-fused-madd\b', cflags) is not None: |
538 os.environ['CFLAGS'] = ( | 538 os.environ['CFLAGS'] = ( |
539 os.environ.get('CFLAGS', '') + ' -Qunused-arguments') | 539 os.environ.get('CFLAGS', '') + ' -Qunused-arguments') |
540 | 540 |
541 setup(name='mercurial', | 541 setup(name='mercurial', |
542 version=setupversion, | 542 version=setupversion, |