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

get_docopts.sh does not support macOS ARM #58

Open
stephenchu opened this issue Apr 13, 2022 · 3 comments
Open

get_docopts.sh does not support macOS ARM #58

stephenchu opened this issue Apr 13, 2022 · 3 comments
Labels
macos waiting for user Some suggestion has been made in the issue, please give some feedback.

Comments

@stephenchu
Copy link

It is due to the pre-built binaries don't have a "darwin" and "arm", I think.

Since M1 macs are out for a while now, do you think the pre-built binary releases can support a new "darwin" "arm" download? Thanks.

@Sylvain303
Copy link
Collaborator

Sylvain303 commented Apr 15, 2022

Hello @stephenchu,

As you may have guessed, I'm not a mac user. Could you give me more details?

The build and pre-build is automated. I can try a cross-compile for your OS and ARCH.

Will you be able to install a golang build environment on you mac? So we could test together how it works.

I didn't look at the pre-build binaries steps for a while. I see some commented line in the Makefile

# build for OSX
docopts-OSX: docopts.go
   env GOOS=darwin go build -o docopts-OSX docopts.go

So I did:

GOOS=darwin GOARCH=arm64 go build -o docopts-arm64-OSX docopts.go

It's compiled from master branch, base64 encoded:

docopts-arm64-OSX.txt

File signature is of the original binary before base64 encoding is:

md5sum docopts-arm64-OSX
8120da3c7138a63f0e8e928e5b4e2aac  docopts-arm64-OSX

You can get back the compiled binary from:

EDIT (added a command to visually check md5 signature)

$ base64 -d < docopts-arm64-OSX.txt > docopts-arm64-OSX
$ chmod a+x ./docopts-arm64-OSX
# verify signature
$ md5sum docopts-arm64-OSX
8120da3c7138a63f0e8e928e5b4e2aac  docopts-arm64-OSX

tell me is it works.

Regards,
Sylvain.

@Sylvain303 Sylvain303 added macos waiting for user Some suggestion has been made in the issue, please give some feedback. labels Apr 15, 2022
@donovanbai-dd
Copy link

I can confirm the binary is working on my M1 mac

@Sylvain303
Copy link
Collaborator

Thanks @donovanbai-dd

I will add this target to the release script. And republish the latest release.

Will it will be done, I will close the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
macos waiting for user Some suggestion has been made in the issue, please give some feedback.
Projects
None yet
Development

No branches or pull requests

3 participants