Add support for GOARM parameter when cross compiling

Go can cross compile to older ARM architectures (e.g. v5). In order to
do so one needs to use the GOARM parameter as documented in
https://github.com/golang/go/wiki/GoArm
This commit is contained in:
Jean-François Paris
2018-02-04 14:06:13 +00:00
parent aa333f4d49
commit e86fb5eedd
2 changed files with 12 additions and 2 deletions

View File

@@ -113,6 +113,8 @@ supply the target OS and platform via the command-line options like this
$ go run build.go --goos freebsd --goarch 386
$ go run build.go --goos linux --goarch arm --goarm 6
The resulting binary is statically linked and does not require any
libraries.