From 4aa0c9f1562d90680c787ba30f3ca4f0123294e0 Mon Sep 17 00:00:00 2001 From: Brett Jia Date: Mon, 13 May 2024 23:39:52 -0400 Subject: [PATCH] build: use gnueabihf for armv7l and armv6l (#314) --- scripts/build.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/scripts/build.py b/scripts/build.py index 4ba635b..3cc0724 100644 --- a/scripts/build.py +++ b/scripts/build.py @@ -19,10 +19,12 @@ def detect_arch(): with open(Path(__file__).parent.parent / "libs.json") as f: archs = json.loads(f.read()) + uname = platform.uname() + glibc_flavor = "gnueabihf" if uname.machine in ["armv7l", "armv6l"] else "gnu" + libc, _ = platform.libc_ver() # https://github.com/python/cpython/issues/87414 - libc = "gnu" if libc == "glibc" else "musl" - uname = platform.uname() + libc = glibc_flavor if libc == "glibc" else "musl" pointer_size = struct.calcsize("P") * 8 for arch in archs: