-
Notifications
You must be signed in to change notification settings - Fork 1.2k
feat: #2392: add arm based ubuntu runner #2494
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@chearon would you be able to take a look at this and move this PR forward? |
I wish it was this easy, but all of the dependencies have to be built for ARM as well. This isn't going to work. My long term plan is to use Zig's build system so that we can cross-compile easily, but that will require trimming dependencies first. |
@chearon what are the dependencies that currently do not support arm? Is it something in the underlying images used to run the prebuilds? If you could left some pointers would be helpful. We are in need for that and likely could help to look into this as well |
Yes. Here's the Dockerfile we use for x86 currently1. The image from it is referenced on line 59R in the diff of this PR. I think you'd need to get an image built for arm64 first, because I don't know how the current one could work with x86. If you're lucky, that Dockerfile will build unmodified, but probably not. I'll certainly help move it along if you/someone wants to take it on, but I'd personally rather work on cross-compiling since the current solution has been a huge pain. 1Dependencies have to be manually built against an old glibc to create a binary that works on the most operating systems. If you publish the libraries from apt-get, they'll cause linker errors on any previous versions of glibc. |
@chearon I believe I got a working image with the changes I'm proposing in the Dockerfile at #2516. On top of that the image in use for the arm64 build context will have to be changed in this PR at https://github.com/Automattic/node-canvas/pull/2494/files#diff-c18dd11250e4e0f0d19035ce56dd87584b7d4f9803ff95437d4831a6d92e938aR59 . Be free to produce your own images and publish those based out of the Dockerfile changes PR. It's not optimal neither a long term solution as the one you have in mind by using Zig all around. But it should be enough to unblock this for now in the same build terms used for all the other current artifacts. 😃 |
Thanks for the cooperation @chearon , really much appreciated 🙏 |
No problem. I don't have hardware to test it, but 3.1.1 is published with ARM binaries. Tests passed on the runner so I assume it's OK. Only catch is the ARM tarball is 20MiB, whereas x86 is 10MiB. For some reason the binary depended on libicu data, so that got bundled. |
Thanks for contributing!
Due to the public availability of the new ubuntu-arm runner on GithubActions I think this is the appropriate time to also include the prebuild for this architecture.