normalize whitespace in Lib/distutils/msvc9compiler.py

This commit is contained in:
Mark Hammond 2011-10-17 11:35:06 +11:00
parent 323b5daa10
commit 3dca9f52a4
1 changed files with 2 additions and 2 deletions

View File

@ -685,7 +685,7 @@ class MSVCCompiler(CCompiler) :
def manifest_get_embed_info(self, target_desc, ld_args): def manifest_get_embed_info(self, target_desc, ld_args):
# If a manifest should be embedded, return a tuple of # If a manifest should be embedded, return a tuple of
# (manifest_filename, resource_id). Returns None if no manifest # (manifest_filename, resource_id). Returns None if no manifest
# should be embedded. See http://bugs.python.org/issue7833 for why # should be embedded. See http://bugs.python.org/issue7833 for why
# we want to avoid any manifest for extension modules if we can) # we want to avoid any manifest for extension modules if we can)
for arg in ld_args: for arg in ld_args:
if arg.startswith("/MANIFESTFILE:"): if arg.startswith("/MANIFESTFILE:"):
@ -728,7 +728,7 @@ class MSVCCompiler(CCompiler) :
manifest_buf = re.sub(pattern, "", manifest_buf) manifest_buf = re.sub(pattern, "", manifest_buf)
pattern = "<dependentAssembly>\s*</dependentAssembly>" pattern = "<dependentAssembly>\s*</dependentAssembly>"
manifest_buf = re.sub(pattern, "", manifest_buf) manifest_buf = re.sub(pattern, "", manifest_buf)
# Now see if any other assemblies are referenced - if not, we # Now see if any other assemblies are referenced - if not, we
# don't want a manifest embedded. # don't want a manifest embedded.
pattern = re.compile( pattern = re.compile(
r"""<assemblyIdentity.*?name=(?:"|')(.+?)(?:"|')""" r"""<assemblyIdentity.*?name=(?:"|')(.+?)(?:"|')"""