From 9ec889b99a7d960b971caec9e6a95e1bb64a768d Mon Sep 17 00:00:00 2001 From: odidev Date: Sat, 1 Aug 2020 20:26:18 +0530 Subject: [PATCH] ARM64 Support to Github Actions for wheel development (#209) Signed-off-by: odidev --- .github/workflows/wheel-builder.yml | 32 +++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/.github/workflows/wheel-builder.yml b/.github/workflows/wheel-builder.yml index d66c191..d905618 100644 --- a/.github/workflows/wheel-builder.yml +++ b/.github/workflows/wheel-builder.yml @@ -116,3 +116,35 @@ jobs: with: name: "bcrypt-${{ github.event.client_payload.BUILD_VERSION }}-${{ matrix.WINDOWS.WINDOWS }}-${{ matrix.PYTHON.VERSION }}" path: bcrypt-wheelhouse\ + + manylinux-arm64: + name: "Python ${{ matrix.PYTHON }} for manylinux2014-aarch64" + runs-on: ubuntu-latest + strategy: + matrix: + PYTHON: ["cp35-cp35m"] + fail-fast: false + steps: + - uses: actions/checkout@v2 + - run: | + docker run --rm --privileged hypriot/qemu-register + - uses: docker://quay.io/pypa/manylinux2014_aarch64 + with: + args: | + bash -c "/opt/python/${{ matrix.PYTHON }}/bin/pip install virtualenv; + /opt/python/${{ matrix.PYTHON }}/bin/python -m virtualenv .venv; + .venv/bin/pip install setuptools wheel cffi six; + REGEX='cp3([0-9])*'; + if [[ ${{ matrix.PYTHON }} =~ $REGEX ]]; then + PY_LIMITED_API=\"--py-limited-api=cp3${BASH_REMATCH[1]}\"; + fi; + .venv/bin/python setup.py bdist_wheel $PY_LIMITED_API -d tmpwheelhouse; + auditwheel repair tmpwheelhouse/bcrypt*.whl -w wheelhouse/; + .venv/bin/pip install bcrypt --no-index -f wheelhouse/; + .venv/bin/python -c \"import bcrypt; password = b'super secret password';hashed = bcrypt.hashpw(password, bcrypt.gensalt());bcrypt.checkpw(password, hashed)\";" + - run: mkdir bcrypt-wheelhouse + - run: sudo mv wheelhouse/bcrypt*.whl bcrypt-wheelhouse/ + - uses: actions/upload-artifact@v1 + with: + name: "bcrypt-${{ github.event.client_payload.BUILD_VERSION }}-manylinux2014-aarch64-${{ matrix.PYTHON }}" + path: bcrypt-wheelhouse/