Skip to content
Merged
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
53 changes: 4 additions & 49 deletions .github/workflows/python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ jobs:
platform:
- runner: ubuntu-22.04
target: x86_64
- runner: ubuntu-22.04
target: aarch64

steps:
- uses: actions/checkout@v4
with:
Expand All @@ -53,62 +56,14 @@ jobs:
else
echo "❌ .z3env not found. Please run the installer script first."
fi
export TARGET_SYSROOT=/usr/local/
# sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: wheels-linux-${{ matrix.platform.target }}
path: crackers_python/dist

linux-arm:
if: ${{ startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' }}
name: Build wheel on ${{ matrix.platform.name }}
runs-on: ubuntu-latest
strategy:
matrix:
platform:
- name: arm64
arch: aarch64

steps:
- name: Checkout code
uses: actions/checkout@v4
with:
submodules: true

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Run on ARM using run-on-arch-action
uses: uraimo/run-on-arch-action@v3
with:
arch: ${{ matrix.platform.arch }}
distro: ubuntu20.04
githubToken: ${{ github.token }}
run: |
set -eux
cd crackers_python

# Install dependencies
apt update
apt install -y curl build-essential python3 python3-pip python3-venv libclang-dev llvm-dev clang libz3-dev

# Install Rust
curl https://sh.rustup.rs -sSf | sh -s -- -y
source "$HOME/.cargo/env"

# Install Maturin
pip3 install maturin[patchelf]

# Build the wheel
maturin build --release --out dist --find-interpreter --manylinux 2_31

- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: wheels-linux-${{ matrix.platform.arch }}
path: crackers_python/dist

# windows:
# runs-on: ${{ matrix.platform.runner }}
# strategy:
Expand Down
4 changes: 2 additions & 2 deletions crackers_python/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[build-system]
requires = [
"maturin>=1.8,<2.0",
"z3-solver==4.12.4.0",
"z3-solver>=4.12.4.0",

]
build-backend = "maturin"
Expand All @@ -16,7 +16,7 @@ classifiers = [
]
dynamic = ["version"]
dependencies = [
"z3-solver==4.12.4.0",
"z3-solver>=4.12.4.0",
]
[tool.maturin]
features = ["pyo3/extension-module"]