Skip to content

Commit 1453f7b

Browse files
longnguyen2004lazka
authored andcommitted
Prefer sysconfig.python_build
1 parent c04f4f7 commit 1453f7b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Lib/distutils/command/build_ext.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,7 @@ def finalize_options(self):
219219
# For extensions under Cygwin, Python's library directory must be
220220
# appended to library_dirs
221221
if sys.platform[:6] == 'cygwin' or self.plat_name.startswith(('mingw')):
222-
if sys.executable.startswith(os.path.join(sys.exec_prefix, "bin")):
222+
if not sysconfig.python_build:
223223
# building third party extensions
224224
config_dir_name = os.path.basename(sysconfig.get_config_var('LIBPL'))
225225
self.library_dirs.append(os.path.join(sys.prefix, "lib",

0 commit comments

Comments
 (0)