Repository navigation
feat: #5695 ship Linux arm64 packages in releases - #5778
Conversation
|
@kukirin-ui By the way, have you built and tested it on Linux ARM64? I don't have a Linux machine available for testing. |
There was a problem hiding this comment.
🟢 Approval recommended
The only remaining finding is a non-blocking documentation-index nit.
No open issues 🎉
What changed in this PR
Adds native Linux arm64 release builds while preserving existing x64 packages.
Changes:
- Adds architecture-specific Linux build scripts and workflow jobs.
- Produces arm64 AppImage, deb, rpm, and tar.gz packages.
- Validates arm64 updater metadata and updates release documentation.
| File | Summary |
|---|---|
scripts/merge-release-artifacts.py |
Validates and merges arm64 Linux metadata. |
packages/website/content/docs/dev/RELEASE.md |
Documents the expanded release matrix; nit: regenerate the stale docs index. |
packages/desktop/package.json |
Adds architecture-specific Linux build commands. |
package.json |
Exposes the new Linux build scripts. |
.github/workflows/release.yml |
Adds native Linux x64 and arm64 release jobs. |
.github/workflows/build.yml |
Adds Linux arm64 PR build validation. |
Review effort: Lite
|
@Jocs Yes, on two setups. GitHub's native arm64 runners (ubuntu-24.04-arm and ubuntu-22.04-arm): the deb installs with apt, Real arm64 hardware: a Samsung Galaxy S26 (aarch64) running Ubuntu in proot with Termux:X11 as the display. The deb from this PR's build installs with apt, One thing we noticed on the device: the first launch failed with |
Closes #5695
Summary
Releases only ship x86_64 Linux packages, while Windows and macOS already get arm64 builds. This adds a
linux-arm64entry to the release matrix (ubuntu-22.04-arm, same Ubuntu version as the x64 release job) and to the PR build matrix (ubuntu-24.04-arm). Both are native arm64 runners, soelectron-rebuildbuilds the native modules for arm64 without any cross-compiling.build:linux:x64andbuild:linux:arm64scripts, like the existing per-arch mac and win scripts.build:linuxis unchanged for local builds.marktext-linux-arm64-<version>.<ext>. The x64 file names stay exactly the same, so existing download links keep working.merge-release-artifacts.pynow also checkslatest-linux-arm64.yml(the file the AppImage updater reads on arm64) the same way it already checkslatest-linux.yml.Type of change
Test plan
There is no test suite for the workflows or the merge script, so we tested it like this:
ubuntu-latest, arm64 onubuntu-24.04-arm, and arm64 onubuntu-22.04-arm(the release runner). All three passed. The x64 job still producesmarktext-linux-0.22.0-dev.{AppImage,snap,deb,rpm,tar.gz}, and the arm64 jobs producemarktext-linux-arm64-0.22.0-dev.{AppImage,deb,rpm,tar.gz}.Architecture: arm64, and themarktextbinary plus the native modules (keytar,ced,native-keymap) are aarch64 ELF files.dist/*.ymluploaded (https://github.com/kukirin-ui/marktext/actions/runs/38985826222) shows electron-builder writeslatest-linux-arm64.ymlpointing at the arm64 AppImage.merge-release-artifacts.pyon mock artifacts for all six builds. It merges cleanly, and it fails as expected whenlatest-linux-arm64.ymlis missing or an arm64 asset is truncated.ubuntu-24.04-armandubuntu-22.04-arm, under Xvfb: https://github.com/kukirin-ui/marktext/actions/runs/39000909285. On both, the deb installs withapt,marktext --versionreportsv0.22.0-dev ... OS: Linux arm64, and the installed app (with the normal Chromium sandbox) and the AppImage (FUSE,--no-sandbox) both open a sample.mdfile, stay running, and show a "sample.md - MarkText" window. Screenshots and logs are uploaded as run artifacts.Notes for reviewers
We did not run the tag-triggered release workflow itself, since it publishes a release. We tested the same build steps through the PR build. The arm64 smoke test ran on GitHub Actions arm64 runners with a virtual display (Xvfb), not on a physical arm64 machine or a desktop session. The reporter offered to test it on Kylin and Ubuntu arm64 hardware.
By submitting this pull request, I confirm that my contribution is made under the terms of the MIT license.