pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/python/cpython/commit/3cd21aa6a1467723ccc85e6411a6cbe7fa81ef76

60c69660fa.css" /> bpo-38468 : Refactor python-config (#16749) Β· python/cpython@3cd21aa Β· GitHub
Skip to content

Commit 3cd21aa

Browse files
bpo-38468 : Refactor python-config (#16749)
* refactor python-config * πŸ“œπŸ€– Added by blurb_it. * Update Misc/NEWS.d/next/Build/2019-10-13-16-18-24.bpo-38468.buCO84.rst Co-Authored-By: Pablo Galindo <Pablogsal@gmail.com> * Use getvar for pyver * Update news entry with affected file. * Update Misc/NEWS.d/next/Build/2019-10-13-16-18-24.bpo-38468.buCO84.rst Co-Authored-By: Victor Stinner <vstinner@python.org> * Update 2019-10-13-16-18-24.bpo-38468.buCO84.rst
1 parent 8d59eb1 commit 3cd21aa

2 files changed

Lines changed: 7 additions & 5 deletions

File tree

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Misc/python-config.in now uses `getvar()` for all still existing `sysconfig.get_config_var()` calls.
2+
Patch by Joannah Nanjekye.

β€ŽMisc/python-config.inβ€Ž

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ except getopt.error:
2525
if not opts:
2626
exit_with_usage()
2727

28-
pyver = sysconfig.get_config_var('VERSION')
2928
getvar = sysconfig.get_config_var
29+
pyver = getvar('VERSION')
3030

3131
opt_flags = [flag for (flag, val) in opts]
3232

@@ -35,10 +35,10 @@ if '--help' in opt_flags:
3535

3636
for opt in opt_flags:
3737
if opt == '--prefix':
38-
print(sysconfig.get_config_var('prefix'))
38+
print(getvar('prefix'))
3939

4040
elif opt == '--exec-prefix':
41-
print(sysconfig.get_config_var('exec_prefix'))
41+
print(getvar('exec_prefix'))
4242

4343
elif opt in ('--includes', '--cflags'):
4444
flags = ['-I' + sysconfig.get_path('include'),
@@ -65,10 +65,10 @@ for opt in opt_flags:
6565
print(' '.join(libs))
6666

6767
elif opt == '--extension-suffix':
68-
print(sysconfig.get_config_var('EXT_SUFFIX'))
68+
print(getvar('EXT_SUFFIX'))
6969

7070
elif opt == '--abiflags':
7171
print(sys.abiflags)
7272

7373
elif opt == '--configdir':
74-
print(sysconfig.get_config_var('LIBPL'))
74+
print(getvar('LIBPL'))

0 commit comments

Comments
Β (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy