]> granicus.if.org Git - python/commitdiff
Bug #1765375: fix stripping of unwanted LDFLAGS.
authorGeorg Brandl <georg@python.org>
Fri, 24 Aug 2007 11:48:37 +0000 (11:48 +0000)
committerGeorg Brandl <georg@python.org>
Fri, 24 Aug 2007 11:48:37 +0000 (11:48 +0000)
 (backport from rev. 57389)

setup.py

index a983b3be2561f44235002c19e5a3d0716cdfd877..65b32ea271b506827cf285f6440221610b930830 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -267,7 +267,8 @@ class PyBuildExt(build_ext):
                 # strip out double-dashes first so that we don't end up with
                 # substituting "--Long" to "-Long" and thus lead to "ong" being
                 # used for a library directory.
-                env_val = re.sub(r'(^|\s+)-(-|(?!%s))' % arg_name[1], '', env_val)
+                env_val = re.sub(r'(^|\s+)-(-|(?!%s))' % arg_name[1],
+                                 ' ', env_val)
                 parser = optparse.OptionParser()
                 # Make sure that allowing args interspersed with options is
                 # allowed