summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordoko@ubuntu.com <doko@ubuntu.com>2016-01-11 20:43:29 (GMT)
committerdoko@ubuntu.com <doko@ubuntu.com>2016-01-11 20:43:29 (GMT)
commit0633cb7d7a19b2b300bf90edd72bf80ff707bfd3 (patch)
treee5ff31e7e23f3bfc10045f6a888a5140c02c26b1
parent37dc2b28834c95d24746c2958e9ea31d3e8d1968 (diff)
parentb2b12172706df5e4686a5fccdcf88ebe22ee5b5f (diff)
downloadcpython-0633cb7d7a19b2b300bf90edd72bf80ff707bfd3.zip
cpython-0633cb7d7a19b2b300bf90edd72bf80ff707bfd3.tar.gz
cpython-0633cb7d7a19b2b300bf90edd72bf80ff707bfd3.tar.bz2
Merge 3.5
-rw-r--r--Lib/sysconfig.py7
-rw-r--r--Misc/NEWS3
2 files changed, 9 insertions, 1 deletions
diff --git a/Lib/sysconfig.py b/Lib/sysconfig.py
index 137932e..9c34be0 100644
--- a/Lib/sysconfig.py
+++ b/Lib/sysconfig.py
@@ -260,7 +260,12 @@ def _parse_makefile(filename, vars=None):
while len(variables) > 0:
for name in tuple(variables):
value = notdone[name]
- m = _findvar1_rx.search(value) or _findvar2_rx.search(value)
+ m1 = _findvar1_rx.search(value)
+ m2 = _findvar2_rx.search(value)
+ if m1 and m2:
+ m = m1 if m1.start() < m2.start() else m2
+ else:
+ m = m1 if m1 else m2
if m is not None:
n = m.group(1)
found = True
diff --git a/Misc/NEWS b/Misc/NEWS
index 089388e..1d1146f 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -131,6 +131,9 @@ Core and Builtins
Library
-------
+- Issue #24705: Fix sysconfig._parse_makefile not expanding ${} vars
+ appearing before $() vars.
+
- Issue #26069: Remove the deprecated apis in the trace module.
- Issue #22138: Fix mock.patch behavior when patching descriptors. Restore