diff options
author | Tarek Ziadé <ziade.tarek@gmail.com> | 2010-01-26 21:21:54 (GMT) |
---|---|---|
committer | Tarek Ziadé <ziade.tarek@gmail.com> | 2010-01-26 21:21:54 (GMT) |
commit | 0276c7ad0b56024f5373ad8f7edca5d77c58df22 (patch) | |
tree | 39ce4043e0a61938793538d047862c5cfddbab5a /Lib | |
parent | b28e5d7e412f592efd930b04dfb004f16083cf5b (diff) | |
download | cpython-0276c7ad0b56024f5373ad8f7edca5d77c58df22.zip cpython-0276c7ad0b56024f5373ad8f7edca5d77c58df22.tar.gz cpython-0276c7ad0b56024f5373ad8f7edca5d77c58df22.tar.bz2 |
reintroduced the names in Distutils for APIs that were relocated
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/distutils/sysconfig.py | 9 | ||||
-rw-r--r-- | Lib/distutils/util.py | 4 |
2 files changed, 13 insertions, 0 deletions
diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py index bb8b512..2d92dab 100644 --- a/Lib/distutils/sysconfig.py +++ b/Lib/distutils/sysconfig.py @@ -21,6 +21,15 @@ from warnings import warn # to avoid this module to shadow it _sysconfig = __import__('sysconfig') +# names defined here to keep backward compatibility +# for APIs that were relocated +get_python_version = _sysconfig.get_python_version +get_config_h_filename = _sysconfig.get_config_h_filename +parse_config_h = _sysconfig.parse_config_h +get_config_vars = _sysconfig.get_config_vars +get_config_var = _sysconfig.get_config_var +from distutils.ccompiler import customize_compiler + _DEPRECATION_MSG = ("distutils.sysconfig.%s is deprecated. " "Use the APIs provided by the sysconfig module instead") diff --git a/Lib/distutils/util.py b/Lib/distutils/util.py index 18d0d2e..8650d45 100644 --- a/Lib/distutils/util.py +++ b/Lib/distutils/util.py @@ -17,6 +17,10 @@ from distutils.errors import DistutilsByteCompileError _sysconfig = __import__('sysconfig') +# kept for backward compatibility +# since this API was relocated +get_platform = _sysconfig.get_platform + def convert_path(pathname): """Return 'pathname' as a name that will work on the native filesystem. |