Skip to content

cmd/dist: when using GOROOT_FINAL, require GOROOT to be explicitly provided #51504

Description

@dmitshur

Based on my current understanding, I think we should make it a fatal error if the GOROOT_FINAL environment variable is set to a non-empty string, but the GOROOT environment variable is unset or set to an empty string. Doing this should reduce the costs of maintaining and developing Go, without negatively affecting utility.

That is, if GOROOT_FINAL needs to be set (rare), it isn't unreasonable to require GOROOT to also be set explicitly in order to avoid possible ambiguity that arises if it isn't set.

This is a follow up from #50893 (comment).

Issue #42563 might be relevant here, in that this requires knowing the explicit environment the user provided while calling make.bash, and not get confused if make.bash itself sets GOROOT.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions