Conversation
|
|
||
| build-mac: | ||
| needs: prepare | ||
| runs-on: macos-14 |
There was a problem hiding this comment.
I wonder if we can still maintain macOS 12 support with this (I'm just assuming we have a similar situation to Linux). GitHub doesn't have runners for older systems however, so probably nothing we can work around with official runners if that's the case.
There was a problem hiding this comment.
Apparently this is a thing: MACOSX_DEPLOYMENT_TARGET
So we can have a build matrix targeting multiple.
Maybe worth looking into: https://tart.run/
Unverified caveat from Claude:
macos-14 is ARM-only (Apple Silicon). If we need to ship x86_64 Intel binaries for macOS 12 users, we’d need macos-14-large (Intel) or cross-compile with --target x86_64-apple-darwin + rustup target add (if Rust). GitHub has deprecated all Intel runners older than macOS 13, and macOS 13 itself is being retired in Dec 2025 — so macos-15-intel is now the recommended Intel runner.
There was a problem hiding this comment.
Looks like we have MACOSX_DEPLOYMENT_TARGET set to 11.
Re Claude's comment, we cross-compile the wheel in tools/build-x64-mac then merge it with the ARM wheel in tools/build_universal_wheel.py - The build process assumes we're on an ARM machine.
|
|
||
| build-linux: | ||
| needs: prepare | ||
| runs-on: ubuntu-22.04 |
There was a problem hiding this comment.
We'll also need to have a separate ARM runner (ubuntu-22.04-arm). The uv launcher has a single Linux package for both x86_64 and aarch64 binaries, but I don't think this is possible to do with Briefcase (We can't merge *.so libs of the Python packages like it's done for Mac): https://github.com/ankitects/anki/blob/main/qt/launcher/lin/build.sh
There was a problem hiding this comment.
Linux support is unfortunately complicated: #4622 (comment)
Still looking into the best solution here.
There was a problem hiding this comment.
| type: choice | ||
| options: | ||
| - beta | ||
| - official |
There was a problem hiding this comment.
Nitpick: stable instead of official?
| fi | ||
|
|
||
| # Validate PEP 440 format (digits separated by dots) | ||
| if ! echo "$version" | grep -qE '^[0-9]+(\.[0-9]+)*$'; then |
There was a problem hiding this comment.
This simple regex doesn't handle beta versions. We should use packaging to validate the version.
| tag_name: ${{ steps.compute.outputs.tag_name }} | ||
| release_name: ${{ steps.compute.outputs.release_name }} | ||
| is_prerelease: ${{ steps.compute.outputs.is_prerelease }} | ||
| steps: |
There was a problem hiding this comment.
Should check the status of the last run of the CI before doing anything. Example:
https://github.com/AnkiHubSoftware/ankihub_addon/blob/35d960fafd566a5babeebed2975a53ed9c6cc289/.github/workflows/create_release.yml#L19
|
I gave this a test on my fork and pushed some fixes. Workflow run: https://github.com/abdnh/anki/actions/runs/23779203758 macOS's .dmg is noticeably large. We can do separate ARM/Intel releases (so no universal builds) as a small improvement, as was the case for Anki releases before the launcher: https://github.com/ankitects/anki/releases/tag/25.02.7 |
No description provided.