From 4cf63f524d5f412a95d4ecd3181cf08f1ad58cba Mon Sep 17 00:00:00 2001 From: "Jason R. Coombs" Date: Sun, 21 Aug 2022 13:28:38 -0400 Subject: [PATCH] In _make_relative, remove deprecation warning. Ref pypa/distutils#169. --- distutils/ccompiler.py | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/distutils/ccompiler.py b/distutils/ccompiler.py index 6b168792..d9bec15e 100644 --- a/distutils/ccompiler.py +++ b/distutils/ccompiler.py @@ -947,16 +947,7 @@ def _make_relative(base): # Chop off the drive no_drive = os.path.splitdrive(base)[1] # If abs, chop off leading / - rel = no_drive[os.path.isabs(no_drive) :] - if rel != base: - msg = ( - f"Absolute path {base!r} is being replaced with a " - f"relative path {rel!r} for outputs. This behavior is " - "deprecated. If this behavior is desired, please " - "comment in pypa/distutils#169." - ) - warnings.warn(msg, DeprecationWarning) - return rel + return no_drive[os.path.isabs(no_drive) :] def shared_object_filename(self, basename, strip_dir=0, output_dir=''): assert output_dir is not None