darcys22/godbledger

Compilation on MacOS

Closed this issue · 4 comments

Eventually will want to support MacOS

  • add to continuous integration
  • add to release script

go run utils/ci.go install on my mac works fine as it appears to default architecture to runtime.GOARCH

continuous integration may be easiest through github actions (see #102)

release script may be trickier (dependencies on xcode perhaps? solved through github action macos runner maybe?)

Yeah so the utils/ci.go file was used to handle those dependency issues in the project that i based it off. They were using this call to do so:

ci.go xgo -- --go=$(GO) --targets=darwin/amd64

I hadnt been able to get xgo working properly. Its possibly a solution however might need some futher research on how other projects are building their releases.

If github actions could solve this it would also be a good option

Github Actions may solve this through a matrix of parallel docker build environments rather than one xgo pattern; check out the action results attached to PR #106

since landing #106:

  • build and test are run in each PR on macos-latest via github actions

after landing #105:

  • make (or make build-native) will work on MacOS to build locally
  • make build-darwin will fire up xgo in a docker container and create a build for MacOS)