aboutsummaryrefslogtreecommitdiffstats
path: root/community/syncthing/only-test-with-race-when-provided.patch
diff options
context:
space:
mode:
authorTBK <tbk@jjtc.eu>2020-03-09 12:22:33 +0100
committerLeo <thinkabit.ukim@gmail.com>2020-03-09 10:51:17 -0300
commit6b4846b21e2d2b45ee11d6be59771ce5836c4e29 (patch)
treeee84805f38d6f945748963dc3777a31980f90dd7 /community/syncthing/only-test-with-race-when-provided.patch
parent57717f897086cdcff8c01e624f86ff4cb55311a6 (diff)
downloadaports-6b4846b21e2d2b45ee11d6be59771ce5836c4e29.tar.gz
aports-6b4846b21e2d2b45ee11d6be59771ce5836c4e29.tar.bz2
aports-6b4846b21e2d2b45ee11d6be59771ce5836c4e29.tar.xz
community/syncthing: upgrade to 1.3.4
Diffstat (limited to 'community/syncthing/only-test-with-race-when-provided.patch')
-rw-r--r--community/syncthing/only-test-with-race-when-provided.patch22
1 files changed, 11 insertions, 11 deletions
diff --git a/community/syncthing/only-test-with-race-when-provided.patch b/community/syncthing/only-test-with-race-when-provided.patch
index 5b8e4c7f4b..236c1e0864 100644
--- a/community/syncthing/only-test-with-race-when-provided.patch
+++ b/community/syncthing/only-test-with-race-when-provided.patch
@@ -1,14 +1,14 @@
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.
-diff -Nru a/build.go b/build.go
---- a/build.go 2017-04-15 07:38:23.000000000 +0000
-+++ b/build.go 2017-05-12 19:26:36.982569748 +0000
-@@ -379,7 +379,7 @@
- func test(pkgs ...string) {
- lazyRebuildAssets()
+
+--- a/build.go
++++ b/build.go
+@@ -364,7 +364,7 @@
-- useRace := runtime.GOARCH == "amd64"
-+ useRace := race && runtime.GOARCH == "amd64"
- switch runtime.GOOS {
- case "darwin", "linux", "freebsd", "windows":
- default:
+ 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")