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

update makefile to account for different arch #92

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ugwuanye
Copy link

Changes

update makefile to account for different arch

Issue link

closes #91

Copy link
Contributor

@aecay aecay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you describe the usecase you are aiming to account for? End users should install osprey through the github downloads page (example for the latest release version; under the "assets" dropdown) -- which already includes binaries for amd and arm architectures.

For local development on macs, the built-in amd64 emulation should be sufficient (which anyway should not be a use case to which our users are exposed). Absent a use case, I am not sure if we need to be making any changes to the makefile in this case. I'm eager to hear more though about the motivations for this PR.

@ugwuanye
Copy link
Author

@aecay I think it is an ehancement to include other architectures. This is because the current task assumes that anyone that uses the makefile is running amd64 which is probably not the case.
You are right this update is not targeted for users who downloads the tool from github asserts.

@aecay
Copy link
Contributor

aecay commented Sep 20, 2023

On my ARM Mac, when I run make build in a fresh clone of this repo and then run ./build/bin/darwin_amd64/osprey --help, the binary executes correctly. This is because ARM macs have amd64 emulation built in. The environments where our developers work are expected to be amd64 mac or win and arm macs. So all the possibilities are covered. I'm not convinced by the tradeoffs of adding exotic architectures such as i386 to our code base. It makes the code more complicated, without any benefit.

Did you run into architecture compatibility problems on your machine while attempting to complie osprey from source? What steps did you take that led to that outcome?

@zemanlx
Copy link
Contributor

zemanlx commented Jun 19, 2024

I think we should be able to to drop GOARCH (and GOOS) from the Makefile and it just works and compiles for whatever architecture and OS developer currently have

$ echo $GOOS:$GOARCH  
:
$ go env GOOS GOARCH 
darwin
amd64

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

Successfully merging this pull request may close these issues.

Build binary for not only amd64
3 participants