diff options
author | William Hubbs <williamh@gentoo.org> | 2021-05-25 19:41:31 -0500 |
---|---|---|
committer | William Hubbs <williamh@gentoo.org> | 2021-05-25 19:41:31 -0500 |
commit | 28fd92fe913eea196eab39b188b0788463c924d0 (patch) | |
tree | 3173dcf5e1dc5124069c8b8d7ce01e5d46d4a0ef /eclass | |
parent | app-emulation/containerd: apply #nowarn properly to -j1 (diff) | |
download | gentoo-28fd92fe913eea196eab39b188b0788463c924d0.tar.gz gentoo-28fd92fe913eea196eab39b188b0788463c924d0.tar.bz2 gentoo-28fd92fe913eea196eab39b188b0788463c924d0.zip |
go-module.eclass: fix GOPROXY export
This variable should be exported in the go-module_set_globals function
since it is not needed unless EGO_SUM is used.
Signed-off-by: William Hubbs <williamh@gentoo.org>
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/go-module.eclass | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/eclass/go-module.eclass b/eclass/go-module.eclass index c9a7ab12eaf0..9d64ad48b431 100644 --- a/eclass/go-module.eclass +++ b/eclass/go-module.eclass @@ -232,6 +232,9 @@ go-module_set_globals() { readonly EGO_SUM_SRC_URI readonly _GOMODULE_GOSUM_REVERSE_MAP + # export the GOPROXY setting + export GOPROXY="file://${T}/go-proxy" + # Set the guard that we are safe _GO_MODULE_SET_GLOBALS_CALLED=1 } @@ -268,7 +271,7 @@ _go-module_src_unpack_gosum() { die "go-module_set_globals must be called in global scope" fi - local goproxy_dir="${T}/go-proxy" + local goproxy_dir="${GOPROXY/file:\/\//}" mkdir -p "${goproxy_dir}" || die # For each Golang module distfile, look up where it's supposed to go, and @@ -293,7 +296,6 @@ _go-module_src_unpack_gosum() { unpack "$f" fi done - export GOPROXY="file://${goproxy_dir}" # Validate the gosum now _go-module_src_unpack_verify_gosum |