Skip to content

Commit 60bc8b9

Browse files
Add support for linux/arm64 wheels.
Update pyproject.toml to build for aarch64 on Linux, and update release_linux.sh to download the corresponding bazelisk binary. Also disable build isolation for Linux to avoid transient PyPI timeout issues. PiperOrigin-RevId: 933297845
1 parent adc0bfd commit 60bc8b9

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

release/kokoro/release_linux.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,8 @@ rm -rf cel_expr_python/*_test.py
203203

204204
echo "Downloading bazelisk on host..."
205205
curl -LO https://github.com/bazelbuild/bazelisk/releases/download/v1.19.0/bazelisk-linux-amd64
206-
chmod +x bazelisk-linux-amd64
206+
curl -LO https://github.com/bazelbuild/bazelisk/releases/download/v1.19.0/bazelisk-linux-arm64
207+
chmod +x bazelisk-linux-amd64 bazelisk-linux-arm64
207208

208209
# Check if pyproject.toml exists before running sed
209210
if [ -f pyproject.toml ]; then

release/pyproject.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,14 +44,17 @@ test-command = "python {project}/cel_basic_test.py"
4444
build-verbosity = 1
4545

4646
[tool.cibuildwheel.linux]
47+
build-frontend = { name = "pip", args = ["--no-build-isolation"] }
48+
archs = ["x86_64", "aarch64"]
4749
manylinux-x86_64-image = "manylinux_2_28"
50+
manylinux-aarch64-image = "manylinux_2_28"
4851
container-engine = "docker; disable_host_mount: True"
4952
# Google's internal Kokoro/RBE network uses a secure MITM proxy that resigns HTTPS
5053
# traffic with an internal Google CA. Since the public manylinux container does not
5154
# trust this CA, git fetches for external dependencies (like @cel-cpp) will fail
5255
# with SSL certificate errors. We disable http.sslVerify inside the container to
5356
# bypass this and allow Bazel to fetch SCM dependencies through the proxy.
54-
before-all = "git config --global http.sslVerify false && echo 'Installing bazelisk' && cp {project}/bazelisk-linux-amd64 /usr/local/bin/bazel"
57+
before-all = "git config --global http.sslVerify false && echo 'Installing bazelisk' && if [ $(uname -m) = 'aarch64' ]; then cp {project}/bazelisk-linux-arm64 /usr/local/bin/bazel; else cp {project}/bazelisk-linux-amd64 /usr/local/bin/bazel; fi"
5558

5659
[tool.cibuildwheel.macos]
5760
before-all = "echo 'Installing bazelisk'; brew install bazelisk"

0 commit comments

Comments
 (0)