autopkg / timsutton-recipes

AutoPkg recipes
16 stars 37 forks source link

Golang now offers both x64 and ARM64 binaries #95

Closed fseesink closed 11 months ago

fseesink commented 2 years ago

More of a question than an issue.

Currently the Go munki recipe is pulling down the Intel x64 binary only. But recently I noticed that they have both x64 and ARM64 specific binaries.

I was just wondering if you intend to add support for the ARM64 binaries?

The current Go.download.recipe uses a RegEx which specifically looks for the x64 .pkg file, so would think it would only take slightly tweaking that from "amd64" to "arm64".

As for how to accomplish this, different folks seem to do it different ways. Seems several apps which previously only offered x64 binaries are now starting to offer ARM64 binaries as well. Wireshark and Go are two examples, as I posted to the devs of those respective Munki repos as well, and the Wireshark repo has already been updated letting users choose which architecture.

Anyway, just figured I would ask.

timsutton commented 2 years ago

Great question. Off the top of my head, I would think to probably keep a single recipe but add the architecture as a new variable that someone can use in their own override/child recipe.

Then, the munki recipe could also set supported_architectures accordingly. Not sure necessarily that needs to be done in the .munki recipe as people could put those into their own overrides instead, but if it works in the recipe as a default then seems reasonable.

At least, that's one approach but welcome other ideas or a PR with a first pass.

timsutton commented 11 months ago

This is now fixed in da5dd6d06172d705c1b746979c0156d1884213df. Enjoy!

fseesink commented 10 months ago

Sorry it took me this long to respond. But just wanted to say thanks! I really appreciated that.

And yes, it works! I updated soon after reading your response, then setup 2 overrides, one for each architecture as I have some x64 and some arm64 Macs. And has been working like a champ. Anyway, didn't want to leave without saying thanks.