From 18c00e63138ffedd493c30b3119e104f6814f6ae Mon Sep 17 00:00:00 2001 From: Christoph Wiedemann <62332054+cwiede@users.noreply.github.com> Date: Wed, 22 Feb 2023 09:49:58 +0100 Subject: [PATCH] aarch64 support --- nexxT/__init__.py | 5 ++++- setup.py | 4 ++-- workspace/SConstruct | 4 ++-- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/nexxT/__init__.py b/nexxT/__init__.py index f1e5e4a..5d2c77f 100644 --- a/nexxT/__init__.py +++ b/nexxT/__init__.py @@ -60,7 +60,10 @@ def internal(self, message, *args, **kws): p = os.environ.get("NEXXT_CEXT_PATH", None) if p is None: variant = os.environ.get("NEXXT_VARIANT", "release") - cplatform = "linux_x86_64" if platform.system() == "Linux" else "msvc_x86_64" + if platform.system() == "Linux": + cplatform = "linux_" + platform.machine() + else: + cplatform = "msvc_x86_64" p = [p for p in [Path(__file__).parent / "binary" / cplatform / variant, Path(__file__).parent / "binary" / cplatform / variant] if p.exists()] if len(p) > 0: diff --git a/setup.py b/setup.py index ca8e874..3fda891 100644 --- a/setup.py +++ b/setup.py @@ -44,7 +44,7 @@ def finalize_options(self): def get_tag(self): python, abi, plat = _bdist_wheel.get_tag(self) # uncomment for non-python extensions - if platform.system() == "Linux": + if platform.system() == "Linux" and platform.machine() == "x86_64": plat = "manylinux_2_28_x86_64" abi = "abi3" python = "cp37" @@ -79,7 +79,7 @@ def is_pure(*args): # return res if platform.system() == "Linux": - p = "linux_x86_64" + p = "linux_" + platform.machine() presuf = [("lib", ".so")] else: p = "msvc_x86_64" diff --git a/workspace/SConstruct b/workspace/SConstruct index 12dd6e7..2e62e2d 100644 --- a/workspace/SConstruct +++ b/workspace/SConstruct @@ -18,9 +18,9 @@ if platform.system() == "Linux": with open("/etc/manylinux-release", "r") as f: target_platform = f.read().strip() else: - target_platform = "linux_x86_64" + target_platform = "linux_" + platform.machine() env = Environment(target_platform=target_platform, - deploy_platform="linux_x86_64", + deploy_platform="linux_" + platform.machine(), toolpath=["#/sconstools3"], ENV = os.environ, variant="unknown")