Skip to content

Commit e646206

Browse files
committed
Revert "TMP: Remove extraneous jobs"
This reverts commit 311226a.
1 parent efb821d commit e646206

File tree

2 files changed

+1523
-0
lines changed

2 files changed

+1523
-0
lines changed

.github/workflows/apple.yml

Lines changed: 252 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,252 @@
1+
name: MacOS Python build
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
schedule:
8+
- cron: '13 11 * * *'
9+
10+
concurrency:
11+
group: ${{ github.workflow }}-${{ github.ref_name }}-${{ github.event.pull_request.number || github.sha }}
12+
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
13+
14+
jobs:
15+
pythonbuild:
16+
runs-on: 'macos-13'
17+
steps:
18+
- uses: actions/checkout@v4
19+
20+
- name: Emit rustc version
21+
run: |
22+
rustc --version > .rustc-version
23+
24+
- uses: actions/cache@v4
25+
with:
26+
path: |
27+
~/.cargo/registry
28+
~/.cargo/git
29+
target
30+
key: ${{ runner.os }}-pythonbuild-${{ hashFiles('Cargo.lock', '.rustc-version') }}
31+
32+
- name: Build
33+
run: |
34+
cargo build --release
35+
36+
- name: Upload pythonbuild Executable
37+
uses: actions/upload-artifact@v4
38+
with:
39+
name: pythonbuild
40+
path: target/release/pythonbuild
41+
42+
build:
43+
strategy:
44+
fail-fast: false
45+
matrix:
46+
build:
47+
- target_triple: 'aarch64-apple-darwin'
48+
runner: macos-14
49+
py: 'cpython-3.9'
50+
options: 'debug'
51+
- target_triple: 'aarch64-apple-darwin'
52+
runner: macos-14
53+
py: 'cpython-3.9'
54+
options: 'pgo'
55+
- target_triple: 'aarch64-apple-darwin'
56+
runner: macos-14
57+
py: 'cpython-3.9'
58+
options: 'pgo+lto'
59+
60+
- target_triple: 'aarch64-apple-darwin'
61+
runner: macos-14
62+
py: 'cpython-3.10'
63+
options: 'debug'
64+
- target_triple: 'aarch64-apple-darwin'
65+
runner: macos-14
66+
py: 'cpython-3.10'
67+
options: 'pgo'
68+
- target_triple: 'aarch64-apple-darwin'
69+
runner: macos-14
70+
py: 'cpython-3.10'
71+
options: 'pgo+lto'
72+
73+
- target_triple: 'aarch64-apple-darwin'
74+
runner: macos-14
75+
py: 'cpython-3.11'
76+
options: 'debug'
77+
- target_triple: 'aarch64-apple-darwin'
78+
runner: macos-14
79+
py: 'cpython-3.11'
80+
options: 'pgo'
81+
- target_triple: 'aarch64-apple-darwin'
82+
runner: macos-14
83+
py: 'cpython-3.11'
84+
options: 'pgo+lto'
85+
86+
- target_triple: 'aarch64-apple-darwin'
87+
runner: macos-14
88+
py: 'cpython-3.12'
89+
options: 'debug'
90+
- target_triple: 'aarch64-apple-darwin'
91+
runner: macos-14
92+
py: 'cpython-3.12'
93+
options: 'pgo'
94+
- target_triple: 'aarch64-apple-darwin'
95+
runner: macos-14
96+
py: 'cpython-3.12'
97+
options: 'pgo+lto'
98+
99+
- target_triple: 'aarch64-apple-darwin'
100+
runner: macos-14
101+
py: 'cpython-3.13'
102+
options: 'debug'
103+
- target_triple: 'aarch64-apple-darwin'
104+
runner: macos-14
105+
py: 'cpython-3.13'
106+
options: 'pgo'
107+
- target_triple: 'aarch64-apple-darwin'
108+
runner: macos-14
109+
py: 'cpython-3.13'
110+
options: 'pgo+lto'
111+
112+
- target_triple: 'aarch64-apple-darwin'
113+
runner: macos-14
114+
py: 'cpython-3.13'
115+
options: 'freethreaded+debug'
116+
- target_triple: 'aarch64-apple-darwin'
117+
runner: macos-14
118+
py: 'cpython-3.13'
119+
options: 'freethreaded+pgo'
120+
- target_triple: 'aarch64-apple-darwin'
121+
runner: macos-14
122+
py: 'cpython-3.13'
123+
options: 'freethreaded+pgo+lto'
124+
125+
# macOS on Intel hardware. This is pretty straightforward. We exclude
126+
# noopt because it doesn't provide any compelling advantages over PGO
127+
# or LTO builds.
128+
- target_triple: 'x86_64-apple-darwin'
129+
runner: macos-13
130+
py: 'cpython-3.9'
131+
options: 'debug'
132+
- target_triple: 'x86_64-apple-darwin'
133+
runner: macos-13
134+
py: 'cpython-3.9'
135+
options: 'pgo'
136+
- target_triple: 'x86_64-apple-darwin'
137+
runner: macos-13
138+
py: 'cpython-3.9'
139+
options: 'pgo+lto'
140+
141+
- target_triple: 'x86_64-apple-darwin'
142+
runner: macos-13
143+
py: 'cpython-3.10'
144+
options: 'debug'
145+
- target_triple: 'x86_64-apple-darwin'
146+
runner: macos-13
147+
py: 'cpython-3.10'
148+
options: 'pgo'
149+
- target_triple: 'x86_64-apple-darwin'
150+
runner: macos-13
151+
py: 'cpython-3.10'
152+
options: 'pgo+lto'
153+
154+
- target_triple: 'x86_64-apple-darwin'
155+
runner: macos-13
156+
py: 'cpython-3.11'
157+
options: 'debug'
158+
- target_triple: 'x86_64-apple-darwin'
159+
runner: macos-13
160+
py: 'cpython-3.11'
161+
options: 'pgo'
162+
- target_triple: 'x86_64-apple-darwin'
163+
runner: macos-13
164+
py: 'cpython-3.11'
165+
options: 'pgo+lto'
166+
167+
- target_triple: 'x86_64-apple-darwin'
168+
runner: macos-13
169+
py: 'cpython-3.12'
170+
options: 'debug'
171+
- target_triple: 'x86_64-apple-darwin'
172+
runner: macos-13
173+
py: 'cpython-3.12'
174+
options: 'pgo'
175+
- target_triple: 'x86_64-apple-darwin'
176+
runner: macos-13
177+
py: 'cpython-3.12'
178+
options: 'pgo+lto'
179+
180+
- target_triple: 'x86_64-apple-darwin'
181+
runner: macos-13
182+
py: 'cpython-3.13'
183+
options: 'debug'
184+
- target_triple: 'x86_64-apple-darwin'
185+
runner: macos-13
186+
py: 'cpython-3.13'
187+
options: 'pgo'
188+
- target_triple: 'x86_64-apple-darwin'
189+
runner: macos-13
190+
py: 'cpython-3.13'
191+
options: 'pgo+lto'
192+
- target_triple: 'x86_64-apple-darwin'
193+
runner: macos-13
194+
py: 'cpython-3.13'
195+
options: 'freethreaded+debug'
196+
- target_triple: 'x86_64-apple-darwin'
197+
runner: macos-13
198+
py: 'cpython-3.13'
199+
options: 'freethreaded+pgo'
200+
- target_triple: 'x86_64-apple-darwin'
201+
runner: macos-13
202+
py: 'cpython-3.13'
203+
options: 'freethreaded+pgo+lto'
204+
needs:
205+
- pythonbuild
206+
runs-on: ${{ matrix.build.runner }}
207+
steps:
208+
- uses: actions/checkout@v4
209+
with:
210+
fetch-depth: 0
211+
212+
- name: Install Python
213+
uses: actions/setup-python@v5
214+
with:
215+
python-version: '3.11'
216+
217+
- name: Download pythonbuild
218+
uses: actions/download-artifact@v4
219+
with:
220+
name: pythonbuild
221+
path: build
222+
223+
- name: Build
224+
run: |
225+
if [ "${{ matrix.build.target_triple }}" = "aarch64-apple-darwin" ]; then
226+
export APPLE_SDK_PATH=/Applications/Xcode_15.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.2.sdk
227+
elif [ "${{ matrix.build.target_triple }}" = "x86_64-apple-darwin" ]; then
228+
export APPLE_SDK_PATH=/Applications/Xcode_15.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.2.sdk
229+
else
230+
echo "unhandled target triple: ${{ matrix.build.target_triple }}"
231+
exit 1
232+
fi
233+
234+
./build-macos.py --target-triple ${{ matrix.build.target_triple }} --python ${{ matrix.build.py }} --options ${{ matrix.build.options }}
235+
236+
- name: Upload Distributions
237+
uses: actions/upload-artifact@v4
238+
with:
239+
name: ${{ matrix.build.py }}-${{ matrix.build.target_triple }}-${{ matrix.build.options }}
240+
path: dist/*
241+
242+
- uses: actions/checkout@v4
243+
with:
244+
repository: 'phracker/MacOSX-SDKs'
245+
ref: master
246+
path: macosx-sdks
247+
248+
- name: Validate Distribution
249+
run: |
250+
chmod +x build/pythonbuild
251+
252+
build/pythonbuild validate-distribution --macos-sdks-path macosx-sdks --run dist/*.tar.zst

0 commit comments

Comments
 (0)