Commit be0a428e authored by Tarek Ziadé's avatar Tarek Ziadé

reintroduced the names in Distutils for APIs that were relocated

parent b9018c0a
...@@ -21,6 +21,15 @@ from warnings import warn ...@@ -21,6 +21,15 @@ from warnings import warn
# to avoid this module to shadow it # to avoid this module to shadow it
_sysconfig = __import__('sysconfig') _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. " _DEPRECATION_MSG = ("distutils.sysconfig.%s is deprecated. "
"Use the APIs provided by the sysconfig module instead") "Use the APIs provided by the sysconfig module instead")
......
...@@ -17,6 +17,10 @@ from distutils.errors import DistutilsByteCompileError ...@@ -17,6 +17,10 @@ from distutils.errors import DistutilsByteCompileError
_sysconfig = __import__('sysconfig') _sysconfig = __import__('sysconfig')
# kept for backward compatibility
# since this API was relocated
get_platform = _sysconfig.get_platform
def convert_path(pathname): def convert_path(pathname):
"""Return 'pathname' as a name that will work on the native filesystem. """Return 'pathname' as a name that will work on the native filesystem.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment