From d8e9d61a955edf6f58c1533012d8a25728ba65be Mon Sep 17 00:00:00 2001 From: Zachary Yedidia Date: Sun, 22 Oct 2023 22:50:27 +0200 Subject: [PATCH] Build arm32 binaries with GOARM=6 Ref #2986 --- tools/compile-linux.sh | 2 +- tools/cross-compile.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/compile-linux.sh b/tools/compile-linux.sh index fca865dd..f5e31784 100755 --- a/tools/compile-linux.sh +++ b/tools/compile-linux.sh @@ -21,7 +21,7 @@ GOOS=linux GOARCH=386 go build -ldflags "-s -w -X main.Version=$1 -X main.Commit tar -czf micro-$1-linux32.tar.gz micro-$1 mv micro-$1-linux32.tar.gz binaries echo "Linux arm 32" -GOOS=linux GOARCH=arm go build -ldflags "-s -w -X main.Version=$1 -X main.CommitHash=$HASH -X 'main.CompileDate=$DATE'" -o micro-$1/micro ./cmd/micro +GOOS=linux GOARM=6 GOARCH=arm go build -ldflags "-s -w -X main.Version=$1 -X main.CommitHash=$HASH -X 'main.CompileDate=$DATE'" -o micro-$1/micro ./cmd/micro tar -czf micro-$1-linux-arm.tar.gz micro-$1 mv micro-$1-linux-arm.tar.gz binaries echo "Linux arm 64" diff --git a/tools/cross-compile.sh b/tools/cross-compile.sh index ea2e6b21..dcd6ca97 100755 --- a/tools/cross-compile.sh +++ b/tools/cross-compile.sh @@ -52,7 +52,7 @@ tar -czf micro-$1-linux32.tar.gz micro-$1 mv micro-$1-linux32.tar.gz binaries echo "Linux ARM 32" -GOOS=linux GOARCH=arm make build +GOOS=linux GOARM=6 GOARCH=arm make build mv micro micro-$1 tar -czf micro-$1-linux-arm.tar.gz micro-$1 mv micro-$1-linux-arm.tar.gz binaries