Skip to content
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

Support ARM builds #179

Closed
trashhalo opened this issue Jan 12, 2023 · 11 comments · Fixed by #278
Closed

Support ARM builds #179

trashhalo opened this issue Jan 12, 2023 · 11 comments · Fixed by #278
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@trashhalo
Copy link

Github actions support arm self hosted runners but setup-beam assumes x86 and errors

Installed Erlang/OTP version follows
  .setup-beam/otp/bin/erl: 1: .setup-beam/otp/bin/../erts-13.1.2/bin/dyn_erl: Exec format error
  .setup-beam/otp/bin/erl: 57: exec: ./erts-13.1.2/bin/erlexec: not found
  Error: The process '/home/runner/actions-runner/_work/_actions/erlef/setup-elixir/v1/dist/install-otp.sh' failed with exit code 127
@paulo-ferraz-oliveira
Copy link
Collaborator

True.

Should this come in the form of an env. variable? Or an input? Or how are you executing this in self-hosted runners?

@trashhalo
Copy link
Author

trashhalo commented Jan 16, 2023 via email

@paulo-ferraz-oliveira
Copy link
Collaborator

Hm... RUNNER_ARCH... that should do it, at least for some cases (I'm not sure all our bundled software supports ARM, but I can create a big enough test to validate it and then make sure we incorporate this, somehow). Thanks for your feedback.

@paulo-ferraz-oliveira
Copy link
Collaborator

Hm... I'm not yet sure how I can test this, actually, unless the online runners (not self-hosted) also support that env. element. If not, it'll have to be by trial-and-error, I guess, maybe with your help.

@paulo-ferraz-oliveira paulo-ferraz-oliveira changed the title support arm builds Support ARM builds Jan 16, 2023
@paulo-ferraz-oliveira
Copy link
Collaborator

I started looking into this and it seems that for all the use cases we've considered, the only one where fetching stuff for ARM would be possible is Gleam (and even then only Mac and Linux, no Windows). We fetch our Erlang/OTP builds from Hex, as well as our Elixir builds, and none of them seem to be available for ARM. Maybe @ericmj can further elaborate or even correct me.

@ericmj
Copy link
Collaborator

ericmj commented Jan 17, 2023

Elixir and Rebar are architecture agnostic.

Bob only builds Erlang for x86/x64. We could provide ARM builds also (we do this for docker images already) but the current build scripts assume x86 so they would need to be modified for any changes ARM requires.

https://github.com/hexpm/bob/blob/main/lib/bob/job/otp_checker.ex
https://github.com/hexpm/bob/tree/main/priv/scripts/otp

@paulo-ferraz-oliveira
Copy link
Collaborator

@ericmj, would you accept pull requests to have the builds produce for ARM, and maybe then this action could use those? We can leave this issue open, still, but this is not a limitation the action can directly work around, at the moment, given what is explained above.

@ericmj
Copy link
Collaborator

ericmj commented Jan 18, 2023

Yes, we would accept PRs. I have linked the places where I think changes need to be made in my previous comment.

@randysecrist
Copy link

randysecrist commented Feb 24, 2023

Just hit this same issue with github actions using self hosted. Watching this issue for updates.

I am also interested in support for alpine > ubuntu as well for smaller overall image sizes. (Although I suspect github will also need to support that here: https://github.com/actions/runner-images)

@paulo-ferraz-oliveira
Copy link
Collaborator

paulo-ferraz-oliveira commented May 31, 2024

There's potential partial support for this in #278. If that gets approved/merged we should retitle this issue Support Windows/ARM (my limited Windows knowledge indicates it runs in ARM these days, too). This'll actually be linked to the pull request and closed when that one's merged. If in need for "other" ARM support, we'll either open a new issue or reopen this one.

@paulo-ferraz-oliveira paulo-ferraz-oliveira linked a pull request May 31, 2024 that will close this issue
2 tasks
@trashhalo
Copy link
Author

Just in time for the official arm release! https://github.blog/2024-06-03-arm64-on-github-actions-powering-faster-more-efficient-build-systems/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants