diff options
author | Benjamin Peterson <benjamin@python.org> | 2014-08-10 03:01:49 (GMT) |
---|---|---|
committer | Benjamin Peterson <benjamin@python.org> | 2014-08-10 03:01:49 (GMT) |
commit | acb8c5234302f8057b331abaafb2cc8697daf58f (patch) | |
tree | c2fcf8f963d5c9755937799022e05e210534211f /setup.py | |
parent | 3b48af018f6a7e7d1d0ec5acefe2890361dbf832 (diff) | |
download | cpython-acb8c5234302f8057b331abaafb2cc8697daf58f.zip cpython-acb8c5234302f8057b331abaafb2cc8697daf58f.tar.gz cpython-acb8c5234302f8057b331abaafb2cc8697daf58f.tar.bz2 |
add -Werror=declaration-after-statement only to stdlib extension modules (closes #21121)
Patch from Stefan Krah.
Diffstat (limited to 'setup.py')
-rw-r--r-- | setup.py | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -19,6 +19,12 @@ from distutils.spawn import find_executable cross_compiling = "_PYTHON_HOST_PLATFORM" in os.environ +# Add special CFLAGS reserved for building the interpreter and the stdlib +# modules (Issue #21121). +cflags = sysconfig.get_config_var('CFLAGS') +py_cflags_nodist = sysconfig.get_config_var('PY_CFLAGS_NODIST') +sysconfig.get_config_vars()['CFLAGS'] = cflags + ' ' + py_cflags_nodist + def get_platform(): # cross build if "_PYTHON_HOST_PLATFORM" in os.environ: |