Skip to content

Commit a8ceb3b

Browse files
committed
Fix _PYTHON_SYSCONFIGDATA_PATH
Signed-off-by: Filipe Laíns <[email protected]>
1 parent d8ffbb4 commit a8ceb3b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Lib/sysconfig/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -341,12 +341,12 @@ def _get_sysconfigdata():
341341
global _SYSCONFIGDATA
342342

343343
if _SYSCONFIGDATA is None:
344+
name = _get_sysconfigdata_name() + '.json'
344345
if '_PYTHON_SYSCONFIGDATA_PATH' in os.environ:
345-
data_path = os.environ['_PYTHON_SYSCONFIGDATA_PATH']
346+
data_path = os.path.join(os.environ['_PYTHON_SYSCONFIGDATA_PATH'], name)
346347
else:
347348
# Search sys.path
348349
# FIXME: We should not need this if we could reliably identify the project directory on source builds
349-
name = _get_sysconfigdata_name() + '.json'
350350
for path in sys.path:
351351
data_path = os.path.join(path, name)
352352
if os.path.isfile(data_path):

0 commit comments

Comments
 (0)