Properly cross-compile for Linux arm64 - #352
Conversation
| - | | ||
| if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then | ||
| mkdir -p prebuilds && chmod 777 prebuilds | ||
| docker build -t node-keytar/i386 docker/i386 |
There was a problem hiding this comment.
Why build it every time, and not just publish it on docker hub?
There was a problem hiding this comment.
Having done this on other OSS projects, unless there's a need for this specific setup from the community I prefer having a fast feedback loop by using the same Dockerfile from the repository.
If this were a bigger project, with a more active CI, I'd re-evaluate and maybe get this publishing to Docker Hub.
shiftkey
left a comment
There was a problem hiding this comment.
Thanks for your persistence on this @dennisameling!
Changes all look good, I'm gonna see if I can publish a release tonight with this included.
|
Thank you so much, @dennisameling. I guess this fixes #318 as well. I'll try to test this out in production. |
|
@quanglam2807 that should indeed fix #318! Please do let me know in case you still run into issues 🚀 |
Identify the Bug
See #347
Fixes #347, successor of/alternative to #349
Description of the Change
After merging this PR, arm64 Linux Electron prebuilds will be created through cross-compilation on a x64 Ubuntu host. This eliminates the need for a native arm64 host as suggested in #349.
Can confirm the generated file now has the proper architecture (tested on Ubuntu 20.04 locally):
Alternate Designs
Possible Drawbacks
None yet - the only downside of cross-compilation is that you won't be able to run automated tests for arm64 on a x64 host natively. The alternative is running tests in a QEMU-emulated arm64 Docker container on a x64 host, or leveraging Travis' native arm64 runners like
lovell/sharpis doing. But the maintainers would need to request OSS credits for travis-ci.com, as .org is shutting down soon. Details in #351Verification Process
Release Notes
Repair arm64 Linux Electron prebuilds