HomeFreeBSD

Mk/Uses/go.mk: Explicitly set modules-aware mode depending on "modules" argument

Description

Mk/Uses/go.mk: Explicitly set modules-aware mode depending on "modules" argument

Until now, go.mk relied on default Go behavior of switching to modules-aware
mode only in the presence of go.mod and building in legacy ("GOPATH") mode
otherwise. This changes with go1.16 [1] which flips defaults to always build in
modules-aware mode and needs an explicit GO111MODULE=off to turn modules off.

Stop relying on Go defaults and set build mode explicitly depending on
"modules" argument in USES=go.

[1] https://github.com/golang/go/issues/41330

Details

Provenance
dmgkAuthored on
Parents
rP560772: www/gobuffalo: Update to 0.16.19
Branches
Unknown
Tags
Unknown