From: Martin v. Löwis Date: Sun, 7 Aug 2005 20:51:04 +0000 (+0000) Subject: Patch #827386: Support absolute source paths in msvccompiler.py. X-Git-Tag: v2.5a0~1531 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b813c53cd892a8de90b0ed172e8964b3e61124df;p=thirdparty%2FPython%2Fcpython.git Patch #827386: Support absolute source paths in msvccompiler.py. Backported to 2.4. --- diff --git a/Lib/distutils/msvccompiler.py b/Lib/distutils/msvccompiler.py index b94d35f15f4d..85d515b20dbc 100644 --- a/Lib/distutils/msvccompiler.py +++ b/Lib/distutils/msvccompiler.py @@ -269,6 +269,8 @@ class MSVCCompiler (CCompiler) : obj_names = [] for src_name in source_filenames: (base, ext) = os.path.splitext (src_name) + base = os.path.splitdrive(base)[1] # Chop off the drive + base = base[os.path.isabs(base):] # If abs, chop off leading / if ext not in self.src_extensions: # Better to raise an exception instead of silently continuing # and later complain about sources and targets having diff --git a/Misc/NEWS b/Misc/NEWS index 8a2d504b43f3..ef879c4c6890 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -178,6 +178,8 @@ Extension Modules Library ------- +- Patch #827386: Support absolute source paths in msvccompiler.py. + - Patch #1105730: Apply the new implementation of commonprefix in posixpath to ntpath, macpath, os2emxpath and riscospath.