ab623 / goeero

An unofficial Eero client written in go
GNU General Public License v3.0
5 stars 1 forks source link

Add AArch32/64 version. #2

Open Nighthawk42 opened 8 months ago

Nighthawk42 commented 8 months ago

While it is not hard to compile for AArch64, it doesn't seem to be included in the releases. Compiling it on your own seems to produce a functional CLI. This would be useful for users who are running ARM-based SoCs like the Raspberry Pi 4 and 5. A similar AArch32 for older ARM devices might also be warranted.

Clone the Repository

git clone https://github.com/ab623/goeero.git cd goeero

Update Go Environment for ARM64

go env -w GOARCH=arm64

Build the eeroclient Binary

go build -o eeroclient cli/eeroclient/main.go

ab623 commented 6 months ago

I can add this into the build script. Is ther a specific GOOS you think we should target?

https://github.com/ab623/goeero/blob/14d986f8141ee149a0d1c5123b3daf2c48fd7976/.github/workflows/release.yml#L18-L26

Nighthawk42 commented 6 months ago

This gist has a great breakdown of available goos, goarch, and platform values. https://gist.github.com/asukakenji/f15ba7e588ac42795f421b48b8aede63

That being said, you might want to target all of the ARM and MIP versions since those are the two popular SoC architectures. If not, just compile it for all of the goarch values. I'm not a Go developer (Python here), but in this usage case, I don't think you need to specify a goos value at all since anyone building it will end up with a viable build for whatever architecture they choose. Once built you'll want to release them all under the 'goarch' values, as OS-agnostic builds.

"386", "amd64", "amd64p32", "arm", "arm64", "arm64be", "armbe", "loong64", "mips", "mips64", "mips64le", "mips64p32", "mips64p32le", "mipsle", "ppc", "ppc64", "ppc64le", "riscv", "riscv64", "s390", "s390x", "sparc", "sparc64", "wasm"