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

Builds for Apple Silicon? #470

Open
ankushg opened this issue Apr 5, 2021 · 8 comments
Open

Builds for Apple Silicon? #470

ankushg opened this issue Apr 5, 2021 · 8 comments
Assignees

Comments

@ankushg
Copy link

ankushg commented Apr 5, 2021

Hi there!

When doing an audit of the binaries on my computer to see which aren't compiled for Apple Silicon, codeclimate test reporter popped up as only having an x86_64 executable

Are there any plans for either an arm64e-specific build, or a universal binary containing an executable for both?

@lmeynberg
Copy link

With now have the possibility to run build jobs on ARM based machine at AWS EC2 it would be even nicer to have that ARM binary.

@mrmachine
Copy link

Indeed. We run GitHub Actions self-hosted runners on arm64 and x64 EC2s to build multi-arch Docker images, and would like to be able to upload coverage reports from both.

@lmeynberg
Copy link

@skydivedan
Copy link

ARM EC2 should work with the ARM64 variant now https://docs.codeclimate.com/docs/configuring-test-coverage#section-locations-of-pre-built-binaries

I see a Linux ARM64 binary. But I don't see a Darwin ARM64 binary. CircleCI recently announced M1 support (Apple Silicon) https://circleci.com/blog/m1-mac-resource-class/. What's awesome about this is that it basically cuts build times in half. But I can't use CodeClimate, because I get this error:

/bin/bash: ./cc-test-reporter: Bad CPU type in executable. - that's because I'm running the wrong binary... the AMD64 binary for MacOS X. But I don't see that there's an alternative.

@atereshkov
Copy link

@skydivedan have you found a solution?

@skydivedan
Copy link

skydivedan commented Mar 29, 2023

Well... I found a workaround.
M1 machines run macOS. macOS on M1 has a layer named "Rosetta" which can run AMD64 binaries, like the current test-reporter. In my case, I'm using CircleCI, and they have the ability to activate Rosetta as a build step. Overhead in this case is very low (2s).
I don't know, for each case, if you are able to do this. It's not ideal, but it does get me around the issue. In my case it's worth it as using M1 machines in CircleCI cut my build time in half (literally, and that's being conservative). YMMV.
That said, it is certainly preferable to use a native version of test-reporter once it exists.

@patoroco
Copy link

patoroco commented Jul 5, 2023

Hi, I've arrived to here with the same issue, but I found a workaround to use the (intel) binary from the Mac, maybe it helps to someone more:

# download the amd64 version for Mac and set the execution permissions
curl -L codeclimate.com/downloads/test-reporter/test-reporter-latest-darwin-amd64 > ~/cc-test-reporter
chmod +x ~/cc-test-reporter

# change the architecture of the shell (Rosetta is needed to do this step)
arch -x86_64 zsh

# Now, you can confirm that the arch on this shell has changed with:
arch

# and you'll be able to execute the binary you've just downloaded:
~/cc-test-reporter

image

@skydivedan
Copy link

Wow, this was brought up nearly 2 ½ years ago... Is anyone looking at this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants