Skip to content

Commit

Permalink
Add linux aarch64 wheel support
Browse files Browse the repository at this point in the history
  • Loading branch information
odidev committed May 19, 2021
1 parent fadfdde commit 14d0d38
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 3 deletions.
9 changes: 8 additions & 1 deletion .github/workflows/wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,19 @@ jobs:
linux:
name: Linux
runs-on: ubuntu-20.04
strategy:
matrix:
arch: [x86_64, aarch64]
steps:
- name: Checkout pygit2
uses: actions/checkout@v2

- name: Set up QEMU
if: ${{ matrix.arch == 'aarch64' }}
uses: docker/setup-qemu-action@v1

- run: |
/bin/sh travis/build-all-manylinux-wheels.sh
/bin/sh travis/build-all-manylinux-wheels.sh ${{ matrix.arch }}
- name: Save wheels
uses: actions/upload-artifact@v2
Expand Down
8 changes: 7 additions & 1 deletion travis/build-all-manylinux-wheels.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,14 @@
set -x
set -e

ARCH=$1

# Wait for docker pull to complete downloading container
manylinux_image="ghcr.io/pyca/cryptography-manylinux2014:x86_64"
f [ $ARCH = 'aarch64' ]; then
manylinux_image="ghcr.io/pyca/cryptography-manylinux2014_${ARCH}"
else
manylinux_image="ghcr.io/pyca/cryptography-manylinux2014:${ARCH}"
fi
docker pull "${manylinux_image}" &
wait

Expand Down
7 changes: 6 additions & 1 deletion travis/build-manylinux-wheels.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,13 @@ export CFLAGS="-fPIC"
export PKG_CONFIG_PATH="${OPENSSL_PATH}/lib/pkgconfig:${PYCA_OPENSSL_PATH}/lib/pkgconfig"

# Install requirements
yum -y install git libffi-devel cmake3
yum -y install git libffi-devel
yum -y install openssl wget
if [ ${ARCH} == 'aarch64' ]; then
yum -y install cmake
else
yum -y install cmake3
fi

# Copy source directory so we don't mangle with it
SRC_DIR=/io/src
Expand Down

0 comments on commit 14d0d38

Please sign in to comment.