Python: fix limited API logic under GCC on Windows

When building a limited API module on Windows the library
to link with should be python3.dll, not python3X.dll. This was
already the case for non-GCC, but should have been the case
unconditionally.
pull/13379/head
Andrew McNulty 4 months ago committed by Eli Schwartz
parent c1e87af9f8
commit 8b757b1f2d
No known key found for this signature in database
GPG Key ID: CEB167EFB5722BD6
  1. 4
      mesonbuild/dependencies/python.py

@ -218,6 +218,8 @@ class _PythonDependencyBase(_Base):
if self.static:
libpath = Path('libs') / f'libpython{vernum}.a'
else:
if limited_api:
vernum = vernum[0]
comp = self.get_compiler()
if comp.id == "gcc":
if imp_lower == 'pypy' and verdot == '3.8':
@ -228,8 +230,6 @@ class _PythonDependencyBase(_Base):
else:
libpath = Path(f'python{vernum}.dll')
else:
if limited_api:
vernum = vernum[0]
if self.is_freethreaded:
libpath = Path('libs') / f'python{vernum}t.lib'
else:

Loading…
Cancel
Save