sky-uk / osprey

Kubernetes OIDC CLI login
BSD 3-Clause "New" or "Revised" License
49 stars 17 forks source link

update makefile to account for different arch #92

Open ugwuanye opened 10 months ago

ugwuanye commented 10 months ago

Changes

update makefile to account for different arch

Issue link

closes #91

ugwuanye commented 10 months ago

@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 commented 10 months ago

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 commented 4 weeks ago

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