Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Version-independent wheel files #98

Merged
merged 1 commit into from
Aug 14, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,23 @@
from setuptools_rust import RustBin
import tomli

try:
# setuptools >= 70.1.0
from setuptools.command.bdist_wheel import bdist_wheel
except ImportError:
from wheel.bdist_wheel import bdist_wheel

def removeprefix(string, prefix):
if string.startswith(prefix):
return string[len(prefix):]
else:
return string

class BdistWheel(bdist_wheel):
def get_tag(self):
_, _, plat = super().get_tag()
return "py3", "none", plat

class Clean(Command):
user_options = []
def initialize_options(self):
Expand Down Expand Up @@ -68,6 +79,7 @@ def run(self):
],
cmdclass={
"clean": Clean,
"bdist_wheel": BdistWheel,
},
classifiers=[
"Development Status :: 2 - Pre-Alpha",
Expand Down
Loading