-
Notifications
You must be signed in to change notification settings - Fork 174
91 lines (79 loc) · 2.52 KB
/
build-kernel-wheels.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
name: Build delta-kernel-rust-sharing-wrapper wheels for 4 OS and 2 architectures
on:
push:
paths:
- python/delta-sharing-kernel/**
- .github/workflows/**
pull_request:
paths:
- python/delta-sharing-kernel/**
- .github/workflows/**
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, ubuntu-20.04, macos-latest, windows-latest]
python-version: [3.8]
arch: [x86_64, arm64]
exclude:
- os: ubuntu-latest
arch: arm64
- os: ubuntu-20.04
arch: arm64
- os: windows-latest
arch: arm64
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install maturin
run: pip install maturin
- name: Build wheel (x86_64 macOS)
if: matrix.os == 'macos-latest' && matrix.arch == 'x86_64'
run: |
rustup target add x86_64-apple-darwin
cd python/delta-kernel-rust-sharing-wrapper
maturin build --release --target x86_64-apple-darwin
shell: bash
- name: Build wheel (ARM macOS)
if: matrix.os == 'macos-latest' && matrix.arch == 'arm64'
run: |
rustup target add aarch64-apple-darwin
cd python/delta-kernel-rust-sharing-wrapper
maturin build --release --target aarch64-apple-darwin
shell: bash
- name: Build wheel (x86_64 Windows)
if: runner.os == 'Windows'
run: |
cd python/delta-kernel-rust-sharing-wrapper
maturin build --release
shell: powershell
- name: Build wheel (x86_64 Linux)
if: matrix.os == 'ubuntu-latest'
run: |
cd python/delta-kernel-rust-sharing-wrapper
maturin build --release
shell: bash
- name: Build wheel (x86_64 Linux Ubuntu 20.04)
if: matrix.os == 'ubuntu-20.04'
run: |
cd python/delta-kernel-rust-sharing-wrapper
maturin build --release
shell: bash
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: wheel-${{ matrix.os }}-${{ matrix.arch }}
path: python/delta-kernel-rust-sharing-wrapper/target/wheels/*.whl
merge:
runs-on: ubuntu-latest
needs: build
steps:
- name: Merge Artifacts
uses: actions/upload-artifact/merge@v4
with:
name: all-wheels
pattern: wheel-*