diff options
| -rw-r--r-- | docs/cross-build.md | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/docs/cross-build.md b/docs/cross-build.md index 317cf23a73..e2fe272f6c 100644 --- a/docs/cross-build.md +++ b/docs/cross-build.md @@ -1,3 +1,5 @@ += armhf = + To cross build for arm you need to install: sudo apt-get install golang-go-linux-arm @@ -16,3 +18,18 @@ As usual, for one-off commands you can simply prepend the environment to the command, e.g. GOARCH=arm GOARM=7 CGO_ENABLED=1 CC=arm-linux-gnueabihf-gcc go build -o snappy_armhf github.com/ubuntu-core/snappy/cmd/snappy + + += arm64 = + +Install: + + sudo apt-get install gcc-aarch64-linux-gnu + +Setup the environment: + + export GOARCH=arm64 CC=aarch64-linux-gnu-gcc CGO_ENABLED=1 + +And then run: + + go build -o snappy_arm64 github.com/ubuntu-core/snappy/cmd/snappy |
