Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 4 Aug 2022 13:21:40 GMT
From:      Dmitri Goutnik <dmgk@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: 998a548dca0d - main - Mk/Uses/go.mk: Pass MAKE_ENV to `go mod tidy` and `go mod vendor`
Message-ID:  <202208041321.274DLe90012136@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by dmgk:

URL: https://cgit.FreeBSD.org/ports/commit/?id=998a548dca0d9a4655c9426e0306299f86a0b37a

commit 998a548dca0d9a4655c9426e0306299f86a0b37a
Author:     Dmitri Goutnik <dmgk@FreeBSD.org>
AuthorDate: 2022-08-04 12:58:43 +0000
Commit:     Dmitri Goutnik <dmgk@FreeBSD.org>
CommitDate: 2022-08-04 13:11:06 +0000

    Mk/Uses/go.mk: Pass MAKE_ENV to `go mod tidy` and `go mod vendor`
    
    With go1.19, these subsommands need to know GOCACHE location, which is
    derived from XDG_CACHE_HOME. Missing XDG_CACHE_HOME breaks poudriere
    user build of Go ports.
    
    PR:             265613
    Reported by:    otis, ohauer
---
 Mk/Uses/go.mk | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/Mk/Uses/go.mk b/Mk/Uses/go.mk
index 91ac5740cf95..9ae32ca267bc 100644
--- a/Mk/Uses/go.mk
+++ b/Mk/Uses/go.mk
@@ -195,9 +195,9 @@ _USES_extract+=	800:go-post-extract
 # already in MODCACHE), vendor them so we can patch them if needed.
 go-post-extract:
 	@${ECHO_MSG} "===> Tidying ${GO_MODNAME} dependencies";
-	@(cd ${GO_WRKSRC}; ${SETENV} ${GO_ENV} GOPROXY=${GO_MODCACHE} ${GO_CMD} mod tidy -e)
+	@(cd ${GO_WRKSRC}; ${SETENV} ${MAKE_ENV} ${GO_ENV} GOPROXY=${GO_MODCACHE} ${GO_CMD} mod tidy -e)
 	@${ECHO_MSG} "===> Vendoring ${GO_MODNAME} dependencies";
-	@(cd ${GO_WRKSRC}; ${SETENV} ${GO_ENV} GOPROXY=${GO_MODCACHE} ${GO_CMD} mod vendor -e)
+	@(cd ${GO_WRKSRC}; ${SETENV} ${MAKE_ENV} ${GO_ENV} GOPROXY=${GO_MODCACHE} ${GO_CMD} mod vendor -e)
 .  else
 # Legacy (GOPATH) build mode, setup directory structure expected by Go for the main module.
 go-post-extract:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202208041321.274DLe90012136>