Skip to content

Commit 37bd7b9

Browse files
fix wrong LIBDIR config on windows
1 parent 8a5e24a commit 37bd7b9

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

‎Lib/sysconfig/__init__.py‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -409,7 +409,10 @@ def _init_non_posix(vars):
409409
),
410410
)
411411

412-
vars['LIBDIR'] = _safe_realpath(os.path.join(get_config_var('installed_base'), 'libs'))
412+
if not _PYTHON_BUILD:
413+
vars['LIBDIR'] = _safe_realpath(os.path.join(get_config_var('installed_base'), 'libs'))
414+
else:
415+
vars['LIBDIR'] = os.path.dirname(_safe_realpath(sys.executable))
413416
if hasattr(sys, 'dllhandle'):
414417
dllhandle = _winapi.GetModuleFileName(sys.dllhandle)
415418
vars['LIBRARY'] = os.path.basename(_safe_realpath(dllhandle))

0 commit comments

Comments
 (0)