mirror of
https://github.com/PaddlePaddle/FastDeploy.git
synced 2026-04-22 16:07:51 +08:00
* [Feature]whl version * [Feature]whl version,set root_is_pure = false * [Feature]code style Co-authored-by: ChowMingSing <610208940@qq.com>
This commit is contained in:
@@ -23,6 +23,7 @@ from functools import lru_cache
|
||||
from pathlib import Path
|
||||
|
||||
import paddle
|
||||
from packaging import tags
|
||||
from setuptools import Extension, find_packages, setup
|
||||
from setuptools.command.build_ext import build_ext
|
||||
from setuptools.command.install import install
|
||||
@@ -42,16 +43,17 @@ PLAT_TO_CMAKE = {
|
||||
|
||||
|
||||
class CustomBdistWheel(bdist_wheel):
|
||||
"""Custom wheel builder for pure Python packages."""
|
||||
"""Custom wheel builder."""
|
||||
|
||||
def finalize_options(self):
|
||||
"""Configure wheel as pure Python and platform-independent."""
|
||||
"""Configure wheel as {python tag}-{abi tag}-{platform tag}."""
|
||||
super().finalize_options()
|
||||
self.root_is_pure = True
|
||||
self.python_tag = "py3"
|
||||
self.abi_tag = "none"
|
||||
tag = next(tags.sys_tags())
|
||||
self.root_is_pure = False
|
||||
self.python_tag = tag.interpreter
|
||||
self.abi_tag = tag.abi
|
||||
self.plat_name_supplied = True
|
||||
self.plat_name = "any"
|
||||
self.plat_name = tag.platform
|
||||
|
||||
|
||||
class CMakeExtension(Extension):
|
||||
|
||||
Reference in New Issue
Block a user