Add workaround for https://github.com/pypa/setuptools/pull/4647
Co-authored-by: Thomas A Caswell <199813+tacaswell@users.noreply.github.com>
This commit is contained in:
parent
dff48c09f5
commit
f1c4650e14
10
setup.py
10
setup.py
@ -10,12 +10,16 @@ cmdclass = {}
|
||||
|
||||
if platform.python_implementation() == "CPython":
|
||||
try:
|
||||
import wheel.bdist_wheel
|
||||
try:
|
||||
from setuptools.command.bdist_wheel import bdist_wheel
|
||||
except ImportError:
|
||||
from wheel.bdist_wheel import bdist_wheel
|
||||
|
||||
class BDistWheel(wheel.bdist_wheel.bdist_wheel):
|
||||
class BDistWheel(bdist_wheel):
|
||||
def finalize_options(self):
|
||||
self.py_limited_api = f"cp3{sys.version_info[1]}"
|
||||
wheel.bdist_wheel.bdist_wheel.finalize_options(self)
|
||||
|
||||
super().finalize_options()
|
||||
|
||||
cmdclass["bdist_wheel"] = BDistWheel
|
||||
except ImportError:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user