From f35937e698cb8252d14fb58fab2a3243532fbc3c Mon Sep 17 00:00:00 2001 From: Craig Condit Date: Thu, 25 Apr 2024 14:53:32 -0500 Subject: [PATCH] [YUNIKORN-2586] Set GOROOT to avoid tool failure when using newer go compilers (#827) Closes: #827 --- Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 92bb7d642..c9d847cea 100644 --- a/Makefile +++ b/Makefile @@ -20,7 +20,9 @@ ifeq ($(GO),) GO := go endif -GO_EXE_PATH := $(shell "$(GO)" env GOROOT)/bin +GOROOT := $(shell "$(GO)" env GOROOT) +export GOROOT := $(GOROOT) +GO_EXE_PATH := $(GOROOT)/bin # Check if this GO tools version used is at least the version of go specified in # the go.mod file. The version in go.mod should be in sync with other repos.