Skip to content

Commit 67c352d

Browse files
committed
Add Linux ARM wheel builds
Signed-off-by: Tim Paine <3105306+timkpaine@users.noreply.github.com>
1 parent 6de693b commit 67c352d

5 files changed

Lines changed: 67 additions & 30 deletions

File tree

‎python/cpp/.github/workflows/build.yaml.jinja‎

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929

3030
strategy:
3131
matrix:
32-
os: [ubuntu-latest, macos-latest, windows-latest]
32+
os: [ubuntu-latest, ubuntu-24.04-arm, macos-latest, windows-latest]
3333
python:
3434
{% if python_version_primary == "3.10" -%}
3535
- version: "3.10"
@@ -104,17 +104,29 @@ jobs:
104104
- name: Install build dependencies
105105
run: pip install cibuildwheel
106106

107-
- name: Build distributions (Linux)
107+
- name: Build distributions (Linux x86_64)
108108
run: |
109109
rm -rf dist
110110
make dist-py-sdist
111111
make dist-py-wheel
112112
make dist-check
113113
env:
114114
CIBW_BUILD: {% raw %}"${{ matrix.python.cibuildwheel }}-manylinux*"{% endraw %}
115+
CIBW_ARCHS_LINUX: native
115116
CIBW_BUILD_VERBOSITY: 3
116117
if: matrix.os == 'ubuntu-latest'
117118

119+
- name: Build distributions (Linux ARM64)
120+
run: |
121+
rm -rf dist
122+
make dist-py-wheel
123+
make dist-check
124+
env:
125+
CIBW_BUILD: {% raw %}"${{ matrix.python.cibuildwheel }}-manylinux*"{% endraw %}
126+
CIBW_ARCHS_LINUX: native
127+
CIBW_BUILD_VERBOSITY: 3
128+
if: matrix.os == 'ubuntu-24.04-arm'
129+
118130
- name: Build distributions (macOS)
119131
run: |
120132
rm -rf dist
@@ -136,7 +148,7 @@ jobs:
136148
uses: actions-ext/python/test-wheel@6e1b91a408ea89f49bc8aff8724f83826f7b5446
137149
with:
138150
module: {{module}}
139-
if: matrix.os == 'ubuntu-latest'
151+
if: runner.os == 'Linux'
140152

141153
- name: Test source distribution
142154
uses: actions-ext/python/test-sdist@6e1b91a408ea89f49bc8aff8724f83826f7b5446

‎python/cpp/pyproject.toml.jinja‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,12 +84,13 @@ replace = 'version = "{new_version}"'
8484

8585
[tool.cibuildwheel]
8686
build = "{% if python_version_primary == '3.10' %}cp310-* {% endif %}{% if python_version_primary in ['3.10', '3.11'] %}cp311-* {% endif %}{% if python_version_primary in ['3.10', '3.11', '3.12'] %}cp312-* {% endif %}cp313-*"
87-
test-command = "echo 'TODO'"
87+
test-command = "pytest -vvv {project}/{{ module }}/tests"
8888
test-extras = "develop"
8989

9090
[tool.cibuildwheel.linux]
91+
manylinux-aarch64-image = "manylinux_2_28"
9192
manylinux-x86_64-image = "manylinux_2_28"
92-
skip = "*i686 musllinux*"
93+
skip = "*i686* *musllinux*"
9394

9495
[tool.cibuildwheel.macos]
9596
environment = {MACOSX_DEPLOYMENT_TARGET="11.0"}

‎python/cppjswasm/.github/workflows/build.yaml.jinja‎

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929

3030
strategy:
3131
matrix:
32-
os: [ubuntu-latest, macos-latest, windows-latest]
32+
os: [ubuntu-latest, ubuntu-24.04-arm, macos-latest, windows-latest]
3333

3434
steps:
3535
- name: Checkout
@@ -93,17 +93,29 @@ jobs:
9393
- name: Install build dependencies
9494
run: pip install cibuildwheel
9595

96-
- name: Build distributions (Linux)
96+
- name: Build distributions (Linux x86_64)
9797
run: |
9898
rm -rf dist
9999
make dist-py-sdist
100100
make dist-py-wheel
101101
make dist-check
102102
env:
103103
CIBW_BUILD: "cp{{ python_version_primary.replace('.', '') }}-manylinux*"
104+
CIBW_ARCHS_LINUX: native
104105
CIBW_BUILD_VERBOSITY: 3
105106
if: matrix.os == 'ubuntu-latest'
106107

108+
- name: Build distributions (Linux ARM64)
109+
run: |
110+
rm -rf dist
111+
make dist-py-wheel
112+
make dist-check
113+
env:
114+
CIBW_BUILD: "cp{{ python_version_primary.replace('.', '') }}-manylinux*"
115+
CIBW_ARCHS_LINUX: native
116+
CIBW_BUILD_VERBOSITY: 3
117+
if: matrix.os == 'ubuntu-24.04-arm'
118+
107119
- name: Build distributions (macOS)
108120
run: |
109121
rm -rf dist
@@ -125,7 +137,7 @@ jobs:
125137
uses: actions-ext/python/test-wheel@6e1b91a408ea89f49bc8aff8724f83826f7b5446
126138
with:
127139
module: {{module}}
128-
if: matrix.os == 'ubuntu-latest'
140+
if: runner.os == 'Linux'
129141

130142
- name: Test source distribution
131143
uses: actions-ext/python/test-sdist@6e1b91a408ea89f49bc8aff8724f83826f7b5446

‎python/rust/.github/workflows/build.yaml.jinja‎

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929

3030
strategy:
3131
matrix:
32-
os: [ubuntu-latest, macos-latest, windows-latest]
32+
os: [ubuntu-latest, ubuntu-24.04-arm, macos-latest, windows-latest]
3333

3434
steps:
3535
- name: Checkout
@@ -79,29 +79,35 @@ jobs:
7979
with:
8080
token: {% raw %}${{ secrets.CODECOV_TOKEN }}{% endraw %}
8181

82-
- name: Set up QEMU
83-
uses: docker/setup-qemu-action@96fe6ef7f33517b61c61be40b68a1882f3264fb8 # v4.2.0
84-
with:
85-
platforms: all
86-
if: runner.os == 'Linux' && runner.arch == 'X64'
87-
8882
- name: Free disk space
8983
run: |
9084
sudo rm -rf /usr/local/lib/android /usr/share/dotnet /opt/ghc /usr/local/.ghcup /usr/share/swift
9185
df -h /
9286
shell: bash
93-
if: matrix.os == 'ubuntu-latest'
87+
if: runner.os == 'Linux'
9488

95-
- name: Build distributions (Linux)
89+
- name: Build distributions (Linux x86_64)
9690
run: |
9791
rm -rf dist
9892
make dist-rs
9993
make dist-py-sdist
10094
make dist-py-wheel
10195
make dist-check
10296
shell: bash
97+
env:
98+
CIBW_ARCHS_LINUX: native
10399
if: matrix.os == 'ubuntu-latest'
104100

101+
- name: Build distributions (Linux ARM64)
102+
run: |
103+
rm -rf dist
104+
make dist-py-wheel
105+
make dist-check
106+
shell: bash
107+
env:
108+
CIBW_ARCHS_LINUX: native
109+
if: matrix.os == 'ubuntu-24.04-arm'
110+
105111
- name: Build distributions (macOS/Windows)
106112
run: |
107113
rm -rf dist
@@ -110,13 +116,13 @@ jobs:
110116
shell: bash
111117
env:
112118
CIBW_ENVIRONMENT_MACOS: MACOSX_DEPLOYMENT_TARGET=11.0
113-
if: matrix.os != 'ubuntu-latest'
119+
if: runner.os != 'Linux'
114120

115121
- name: Test wheel
116122
uses: actions-ext/python/test-wheel@6e1b91a408ea89f49bc8aff8724f83826f7b5446
117123
with:
118124
module: {{module}}
119-
if: matrix.os == 'ubuntu-latest'
125+
if: runner.os == 'Linux'
120126

121127
- name: Test source distribution
122128
uses: actions-ext/python/test-sdist@6e1b91a408ea89f49bc8aff8724f83826f7b5446

‎python/rustjswasm/.github/workflows/build.yaml.jinja‎

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929

3030
strategy:
3131
matrix:
32-
os: [ubuntu-latest, macos-latest, windows-latest]
32+
os: [ubuntu-latest, ubuntu-24.04-arm, macos-latest, windows-latest]
3333

3434
steps:
3535
- name: Checkout
@@ -85,29 +85,35 @@ jobs:
8585
with:
8686
token: {% raw %}${{ secrets.CODECOV_TOKEN }}{% endraw %}
8787

88-
- name: Set up QEMU
89-
uses: docker/setup-qemu-action@96fe6ef7f33517b61c61be40b68a1882f3264fb8 # v4.2.0
90-
with:
91-
platforms: all
92-
if: runner.os == 'Linux' && runner.arch == 'X64'
93-
9488
- name: Free disk space
9589
run: |
9690
sudo rm -rf /usr/local/lib/android /usr/share/dotnet /opt/ghc /usr/local/.ghcup /usr/share/swift
9791
df -h /
9892
shell: bash
99-
if: matrix.os == 'ubuntu-latest'
93+
if: runner.os == 'Linux'
10094

101-
- name: Build distributions (Linux)
95+
- name: Build distributions (Linux x86_64)
10296
run: |
10397
rm -rf dist
10498
make dist-rs
10599
make dist-py-sdist
106100
make dist-py-wheel
107101
make dist-check
108102
shell: bash
103+
env:
104+
CIBW_ARCHS_LINUX: native
109105
if: matrix.os == 'ubuntu-latest'
110106

107+
- name: Build distributions (Linux ARM64)
108+
run: |
109+
rm -rf dist
110+
make dist-py-wheel
111+
make dist-check
112+
shell: bash
113+
env:
114+
CIBW_ARCHS_LINUX: native
115+
if: matrix.os == 'ubuntu-24.04-arm'
116+
111117
- name: Build distributions (macOS/Windows)
112118
run: |
113119
rm -rf dist
@@ -116,13 +122,13 @@ jobs:
116122
shell: bash
117123
env:
118124
CIBW_ENVIRONMENT_MACOS: MACOSX_DEPLOYMENT_TARGET=11.0
119-
if: matrix.os != 'ubuntu-latest'
125+
if: runner.os != 'Linux'
120126

121127
- name: Test wheel
122128
uses: actions-ext/python/test-wheel@6e1b91a408ea89f49bc8aff8724f83826f7b5446
123129
with:
124130
module: {{module}}
125-
if: matrix.os == 'ubuntu-latest'
131+
if: runner.os == 'Linux'
126132

127133
- name: Test source distribution
128134
uses: actions-ext/python/test-sdist@6e1b91a408ea89f49bc8aff8724f83826f7b5446

0 commit comments

Comments
 (0)