Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 36 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,36 @@ jobs:
- store_artifacts:
path: dist

build-linux-aarch64-core:
machine:
image: ubuntu-2204:2023.04
resource_class: arm.medium
environment:
CIBW_ARCHS: "aarch64"
CIBW_BUILD: "cp39-* cp310-* cp311-* cp312-*"
steps:
- checkout
- compress_ext
- restore_cache:
key: ext-linux-aarch64-{{ checksum "ext_concat" }}
- run:
name: Install build dependencies and cibuildwheel
command: |
sudo apt-get update
sudo apt-get install -y python3 python3-venv python3-pip git build-essential
python3 -m pip install --upgrade pip
python3 -m pip install cibuildwheel
- run:
name: Build wheels (Linux aarch64)
command: |
cibuildwheel --platform linux --archs aarch64
- save_cache:
key: ext-linux-aarch64-{{ checksum "ext_concat" }}
paths:
- src/tmlt/core/ext
- store_artifacts:
path: wheelhouse

workflows:
build-core-mac-wheels-workflow:
jobs:
Expand All @@ -73,3 +103,9 @@ workflows:
only: dev
tags:
only: /.*/
- build-linux-aarch64-core:
filters:
branches:
only: dev
tags:
only: /.*/
28 changes: 27 additions & 1 deletion .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,32 @@ package:
interruptible: true
tags: [saas-linux-large-amd64]

# Build Linux aarch64 wheels via cibuildwheel/QEMU in Docker
package_linux_aarch64:
extends: .base
stage: setup
needs: []
image: registry.gitlab.com/tumult-labs/ops/ci/linux:python3.9
services:
- name: docker:dind
entrypoint: ["env", "-u", "DOCKER_HOST"]
command: ["dockerd-entrypoint.sh"]
variables:
DOCKER_HOST: tcp://docker:2375/
DOCKER_DRIVER: overlay2
DOCKER_TLS_CERTDIR: ""
# Tell cibuildwheel to build only Linux aarch64 wheels
CIBW_ARCHS_LINUX: "aarch64"
CIBW_BUILD: "cp39-* cp310-* cp311-* cp312-*"
script:
- curl -sSL https://get.docker.com/ | sh
- nox -s build
artifacts:
paths: ["dist/"]
timeout: 45m
interruptible: true
tags: [saas-linux-large-amd64]

# Requires the AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY variables to be set.
# We use an access key from the core-ci AWS user, which has permissions to list
# and modify all objects in the tumult.core-wheel-cache bucket.
Expand Down Expand Up @@ -467,7 +493,7 @@ audit:

publish:
stage: release
dependencies: [get_mac_wheels, package]
dependencies: [get_mac_wheels, package, package_linux_aarch64]
image: registry.gitlab.com/tumult-labs/ops/ci/linux:python3.9
script:
- poetry publish -u __token__ -p "${RELEASE_PYPI_TOKEN}"
Expand Down
2 changes: 1 addition & 1 deletion ext/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
build_command = ["bash", str(build_dir / "build.sh")]

SUPPORTED_PLATFORMS = ["Linux", "Darwin"]
SUPPORTED_ARCHITECTURES = ["x86_64", "arm64"]
SUPPORTED_ARCHITECTURES = ["x86_64", "arm64", "aarch64"]


def check_platform():
Expand Down
8 changes: 2 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ readme = "README.md"
authors = []
license = "Apache-2.0"

dynamic = ["version"]
version = "0.18.2+hotfix.pr"

classifiers = [
"Development Status :: 4 - Beta",
Expand Down Expand Up @@ -110,13 +110,9 @@ scripting = [
# Build configuration

[build-system]
requires = ["hatchling", "uv-dynamic-versioning"]
requires = ["hatchling"]
build-backend = "hatchling.build"

[tool.hatch.version]
source = "uv-dynamic-versioning"

[tool.uv-dynamic-versioning]
vcs = "git"
style = "semver"
# The default configuration expect vX.Y.Z, but we haven't been using the 'v' prefix.
Expand Down