mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-22 10:45:15 +03:00
14 lines
495 B
Diff
14 lines
495 B
Diff
Only use -race when -race is also given to build.go on the command line:
|
|
x86_64 musl targets do not support the Go race runtime.
|
|
|
|
--- a/build.go
|
|
+++ b/build.go
|
|
@@ -364,7 +364,7 @@
|
|
|
|
args := []string{"test", "-short", "-timeout", timeout, "-tags", "purego"}
|
|
|
|
- if runtime.GOARCH == "amd64" {
|
|
+ if race && runtime.GOARCH == "amd64" {
|
|
switch runtime.GOOS {
|
|
case "darwin", "linux", "freebsd": // , "windows": # See https://github.com/golang/go/issues/27089
|
|
args = append(args, "-race")
|