From 9085020bb39b530d125724c0572ddd497a89556d Mon Sep 17 00:00:00 2001 From: odidev Date: Fri, 28 Jan 2022 17:40:52 +0530 Subject: Add linux aarch64 wheel build support Signed-off-by: odidev --- Makefile | 14 +++++++++++--- build-manylinux1-wheels.sh | 4 ++-- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 0615af3..767db19 100644 --- a/Makefile +++ b/Makefile @@ -5,7 +5,7 @@ RABBIT_DIST=librabbitmq # Distribuition tools PYTHON=python -all: build +all: build manylinux2014 add-submodules: -git submodule add -b v0.8.0 https://github.com/alanxz/rabbitmq-c.git @@ -57,8 +57,16 @@ $(RABBIT_TARGET): dist: rabbitmq-c $(RABBIT_TARGET) -manylinux1: dist - docker run --rm -v `pwd`:/workspace:z quay.io/pypa/manylinux1_x86_64 /workspace/build-manylinux1-wheels.sh +manylinux2014: manylinux2014_x86_64 manylinux2014_aarch64 + +manylinux2014_x86_64: dist + docker run --rm -v `pwd`:/workspace:z quay.io/pypa/manylinux2014_x86_64 /workspace/build-manylinux1-wheels.sh + +qemu-user-static: + docker run --rm --privileged hypriot/qemu-register + +manylinux2014_aarch64: qemu-user-static + docker run --rm -v `pwd`:/workspace:z quay.io/pypa/manylinux2014_aarch64 /workspace/build-manylinux1-wheels.sh rebuild: $(PYTHON) setup.py build diff --git a/build-manylinux1-wheels.sh b/build-manylinux1-wheels.sh index 5423e8e..9b188c5 100755 --- a/build-manylinux1-wheels.sh +++ b/build-manylinux1-wheels.sh @@ -6,7 +6,7 @@ set -e -x yum install -y cmake openssl-devel gcc automake # Compile wheels -for PYBIN in /opt/python/*/bin; do +for PYBIN in /opt/python/cp*/bin; do # Ensure a fresh build of rabbitmq-c. (cd /workspace && PATH="${PYBIN}:${PATH}" make clean) (cd /workspace && "${PYBIN}"/python setup.py install) @@ -23,7 +23,7 @@ for whl in wheelhouse/*linux*.whl; do done # Install packages and test -for PYBIN in /opt/python/*/bin/; do +for PYBIN in /opt/python/cp*/bin/; do PYVER=$(echo "${PYBIN}" | cut -d'/' -f 4) # amqp 5.0.0a1 and vine 5.0.0a1 breaks python2 -- cgit v1.2.1