Skip to content

Commit 55d3d81

Browse files
[3.13] gh-128978: Fix a NameError in sysconfig.expand_makefile_vars (GH-128979) (#129065)
gh-128978: Fix a `NameError` in `sysconfig.expand_makefile_vars` (GH-128979) This fixes a regression introduced by 4a53a39. (cherry picked from commit df66ff1) Co-authored-by: Bénédikt Tran <[email protected]>
1 parent 0351ed5 commit 55d3d81

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

Lib/sysconfig/__init__.py

+3
Original file line numberDiff line numberDiff line change
@@ -695,6 +695,9 @@ def expand_makefile_vars(s, vars):
695695
"""
696696
import re
697697

698+
_findvar1_rx = r"\$\(([A-Za-z][A-Za-z0-9_]*)\)"
699+
_findvar2_rx = r"\${([A-Za-z][A-Za-z0-9_]*)}"
700+
698701
# This algorithm does multiple expansion, so if vars['foo'] contains
699702
# "${bar}", it will expand ${foo} to ${bar}, and then expand
700703
# ${bar}... and so forth. This is fine as long as 'vars' comes from
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Fix a :exc:`NameError` in :func:`!sysconfig.expand_makefile_vars`. Patch by
2+
Bénédikt Tran.

0 commit comments

Comments
 (0)