crossbuild.bash: skip Apple Silicon build on old Go versions

This commit is contained in:
Jakob Unterwurzacher 2021-06-06 21:10:24 +02:00
parent e44d4fcb96
commit a08ef90811

View File

@ -20,8 +20,12 @@ GOOS=linux GOARCH=arm64 $B
# MacOS on Intel # MacOS on Intel
GOOS=darwin GOARCH=amd64 $B GOOS=darwin GOARCH=amd64 $B
# MacOS on Apple Silicon M1 # MacOS on Apple Silicon M1.
GOOS=darwin GOARCH=arm64 $B # Go 1.16 added support for the M1 and added ios/arm64,
# so we use this to check if we should attempt a build.
if go tool dist list | grep ios/arm64 ; then
GOOS=darwin GOARCH=arm64 $B
fi
# The cross-built binary is not useful on the compile host. # The cross-built binary is not useful on the compile host.
rm gocryptfs rm gocryptfs