aboutsummaryrefslogtreecommitdiff
path: root/src/cmd
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2021-04-14 12:38:20 -0400
committerRuss Cox <rsc@golang.org>2021-04-23 21:48:49 +0000
commitb8fed48a9ae7e6229a4fdccf6aae7bc670f61aca (patch)
treede38d9e6355946685544ceed90070e973f2d39de /src/cmd
parenta6d3dc40c40c8a93e6b8bd641104d7655eb5093b (diff)
downloadgo-b8fed48a9ae7e6229a4fdccf6aae7bc670f61aca.tar.xz
cmd/dist: enable cgo on windows/arm64
Change-Id: I4d470e2af1bfb4fba004a6f3e00a163a575593da Reviewed-on: https://go-review.googlesource.com/c/go/+/312047 Trust: Russ Cox <rsc@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com> Reviewed-by: Ian Lance Taylor <iant@golang.org>
Diffstat (limited to 'src/cmd')
-rw-r--r--src/cmd/dist/build.go2
-rw-r--r--src/cmd/dist/test.go6
2 files changed, 5 insertions, 3 deletions
diff --git a/src/cmd/dist/build.go b/src/cmd/dist/build.go
index 63dd8005e3..28c814d316 100644
--- a/src/cmd/dist/build.go
+++ b/src/cmd/dist/build.go
@@ -1598,7 +1598,7 @@ var cgoEnabled = map[string]bool{
"windows/386": true,
"windows/amd64": true,
"windows/arm": false,
- "windows/arm64": false,
+ "windows/arm64": true,
}
// List of platforms which are supported but not complete yet. These get
diff --git a/src/cmd/dist/test.go b/src/cmd/dist/test.go
index 5ae0bf92cf..8b1ec458ed 100644
--- a/src/cmd/dist/test.go
+++ b/src/cmd/dist/test.go
@@ -976,6 +976,9 @@ func (t *tester) internalLink() bool {
if goos == "ios" {
return false
}
+ if goos == "windows" && goarch == "arm64" {
+ return false
+ }
// Internally linking cgo is incomplete on some architectures.
// https://golang.org/issue/10373
// https://golang.org/issue/14449
@@ -1108,8 +1111,7 @@ func (t *tester) cgoTest(dt *distTest) error {
cmd := t.addCmd(dt, "misc/cgo/test", t.goTest())
cmd.Env = append(os.Environ(), "GOFLAGS=-ldflags=-linkmode=auto")
- // Skip internal linking cases on arm64 to support GCC-9.4 and above,
- // only for linux, conservatively.
+ // Skip internal linking cases on linux/arm64 to support GCC-9.4 and above.
// See issue #39466.
skipInternalLink := goarch == "arm64" && goos == "linux"