From e6ab556f0e162888f24ef1ef44bfb56cd6ed1f37 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Wed, 23 Aug 2017 11:18:26 -0400 Subject: [PATCH] Only use race flag on amd64 Race is only supported on amd64, so only run if GOARCH is amd64 Signed-off-by: Christopher Jones --- Makefile.darwin | 6 ++++-- Makefile.freebsd | 6 ++++-- Makefile.linux | 6 ++++-- Makefile.windows | 6 ++++-- 4 files changed, 16 insertions(+), 8 deletions(-) diff --git a/Makefile.darwin b/Makefile.darwin index ab8ac344f..3011704bd 100644 --- a/Makefile.darwin +++ b/Makefile.darwin @@ -1,5 +1,7 @@ #darwin specific settings COMMANDS += containerd-shim -# supports go test -race -TESTFLAGS_RACE= -race +# amd64 supports go test -race +ifeq ("amd64", $(GOARCH)) + TESTFLAGS_RACE= -race +endif diff --git a/Makefile.freebsd b/Makefile.freebsd index 675d6caa5..4548eb1cd 100644 --- a/Makefile.freebsd +++ b/Makefile.freebsd @@ -1,5 +1,7 @@ #freebsd specific settings COMMANDS += containerd-shim -# supports go test -race -TESTFLAGS_RACE= -race +# amd64 supports go test -race +ifeq ("amd64", $(GOARCH)) + TESTFLAGS_RACE= -race +endif diff --git a/Makefile.linux b/Makefile.linux index 0bf02ec3a..01b9ceb6c 100644 --- a/Makefile.linux +++ b/Makefile.linux @@ -1,5 +1,7 @@ #linux specific settings COMMANDS += containerd-shim -# supports go test -race -TESTFLAGS_RACE= -race +# amd64 supports go test -race +ifeq ("amd64", $(GOARCH)) + TESTFLAGS_RACE= -race +endif diff --git a/Makefile.windows b/Makefile.windows index 6db1e603d..d41401211 100644 --- a/Makefile.windows +++ b/Makefile.windows @@ -5,5 +5,7 @@ FIX_PATH = $(subst /,\,$1) BINARY_SUFFIX=".exe" -# supports go test -race -TESTFLAGS_RACE= -race +# amd64 supports go test -race +ifeq ("amd64", $(GOARCH)) + TESTFLAGS_RACE= -race +endif