Skip to content

"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files

build: support mount on windows/arm64 - all windows binaries now not cgo

Nick Craig-Wooddeab86867c23
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 84abb827c..784a236cc 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -25,7 +25,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- job_name: ['linux', 'mac_amd64', 'mac_arm64', 'windows_amd64', 'windows_386', 'other_os', 'go1.16', 'go1.17']
+ job_name: ['linux', 'mac_amd64', 'mac_arm64', 'windows', 'other_os', 'go1.16', 'go1.17']
include:
- job_name: linux
@@ -55,23 +55,12 @@ jobs:
build_flags: '-include "^darwin/arm64" -cgo -macos-arch arm64 -cgo-cflags=-I/usr/local/include -cgo-ldflags=-L/usr/local/lib'
deploy: true
- - job_name: windows_amd64
+ - job_name: windows
os: windows-latest
go: '1.18.x'
gotags: cmount
- build_flags: '-include "^windows/amd64" -cgo'
- build_args: '-buildmode exe'
- quicktest: true
- racequicktest: true
- deploy: true
-
- - job_name: windows_386
- os: windows-latest
- go: '1.18.x'
- gotags: cmount
- goarch: '386'
- cgo: '1'
- build_flags: '-include "^windows/386" -cgo'
+ cgo: '0'
+ build_flags: '-include "^windows/"'
build_args: '-buildmode exe'
quicktest: true
deploy: true
@@ -79,7 +68,7 @@ jobs:
- job_name: other_os
os: ubuntu-latest
go: '1.18.x'
- build_flags: '-exclude "^(windows/(386|amd64)|darwin/|linux/)"'
+ build_flags: '-exclude "^(windows/|darwin/|linux/)"'
compile_all: true
deploy: true
diff --git a/Makefile b/Makefile
index c155b2240..f96e1d92a 100644
--- a/Makefile
+++ b/Makefile
@@ -97,7 +97,7 @@ release_dep_linux:
# Get the release dependencies we only install on Windows
release_dep_windows:
- GO111MODULE=off GOOS="" GOARCH="" go get github.com/josephspurrier/goversioninfo/cmd/goversioninfo
+ GOOS="" GOARCH="" go install github.com/josephspurrier/goversioninfo/cmd/goversioninfo@latest
# Update dependencies
showupdates:
diff --git a/bin/cross-compile.go b/bin/cross-compile.go
index 2d10dec88..405f1b79c 100644
--- a/bin/cross-compile.go
+++ b/bin/cross-compile.go
@@ -265,9 +265,12 @@ func buildWindowsResourceSyso(goarch string, versionTag string) string {
"-o",
sysoPath,
}
- if goarch == "amd64" {
+ if strings.Contains(goarch, "64") {
args = append(args, "-64") // Make the syso a 64-bit coff file
}
+ if strings.Contains(goarch, "arm") {
+ args = append(args, "-arm") // Make the syso an arm binary
+ }
args = append(args, jsonPath)
err = runEnv(args, nil)
if err != nil {