Skip to content

Commit 5d62bc9

Browse files
committed
Add armv7 smoke test (cross-build + QEMU import check)
PRs never exercised the armv7 path: tests.yml only builds wheels on release/dispatch. Add a smoke job that cross-builds the armv7l wheels (fast, no emulation) and then boots them in an armv7 container under QEMU to assert 'python -m av --version' imports and loads FFmpeg.
1 parent f1f8040 commit 5d62bc9

1 file changed

Lines changed: 42 additions & 0 deletions

File tree

.github/workflows/smoke.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,3 +157,45 @@ jobs:
157157
. $CONDA/etc/profile.d/conda.sh
158158
conda activate pyav
159159
python -m pytest
160+
161+
armv7:
162+
name: "armv7 cross-build + qemu smoke"
163+
runs-on: ubuntu-24.04
164+
steps:
165+
- uses: actions/checkout@v6
166+
- name: Set up host Python 3.11
167+
uses: actions/setup-python@v6
168+
with:
169+
python-version: "3.11"
170+
- name: Set up host Python 3.14t
171+
uses: actions/setup-python@v6
172+
with:
173+
python-version: "3.14t"
174+
- name: Install build tooling
175+
run: |
176+
for py in python3.11 python3.14t; do
177+
$py -m pip install -U "cython>=3.1.0,<4" "setuptools>=77.0" wheel
178+
done
179+
# patchelf 0.18 (ubuntu-24.04's system version) corrupts ELF files
180+
# with large p_align; pin <0.18 for auditwheel to use.
181+
python3.11 -m pip install -U ziglang auditwheel 'patchelf<0.18'
182+
- name: Cross-compile armv7l wheels with zig
183+
env:
184+
HOST_PY311: python3.11
185+
HOST_PY314T: python3.14t
186+
TOOLS_PY: python3.11
187+
run: bash scripts/build-armv7l-cross.sh
188+
- name: Set up QEMU
189+
uses: docker/setup-qemu-action@v3
190+
with:
191+
platforms: arm
192+
- name: Import-test wheels under emulation
193+
run: |
194+
docker run --rm --platform linux/arm/v7 -v "$PWD/dist:/dist:ro" \
195+
quay.io/pypa/manylinux_2_31_armv7l bash -ceu '
196+
for py in /opt/python/cp311-cp311 /opt/python/cp314-cp314t; do
197+
echo "::group::$("$py/bin/python" --version)"
198+
"$py/bin/pip" install --no-index --find-links /dist av
199+
"$py/bin/python" -m av --version
200+
echo "::endgroup::"
201+
done'

0 commit comments

Comments
 (0)