]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/dist: set GOFLAGS=-trimpath when building cmd for releases
authorBryan C. Mills <bcmills@google.com>
Fri, 27 Jan 2023 20:33:48 +0000 (15:33 -0500)
committerGopher Robot <gobot@golang.org>
Tue, 31 Jan 2023 15:28:44 +0000 (15:28 +0000)
Also set it on the Go builders, so that the builders more closely
match releases.

It looks like this change was intended to be included in CL 454836,
but was commented out at some point — perhaps during debugging? —
before that change was merged.

For #24904.

Change-Id: Ib501274520c5de366d4e9d87a1bd3c6ba2d2413f
Reviewed-on: https://go-review.googlesource.com/c/go/+/463740
Run-TryBot: Bryan Mills <bcmills@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Russ Cox <rsc@golang.org>
Auto-Submit: Bryan Mills <bcmills@google.com>

src/cmd/dist/build.go

index 1b6a2ceae09c1f8063fb5d4f668b47ebb113b6eb..d388058d9eda681cd52a434e1ebe315c3bf2b53b 100644 (file)
@@ -1296,10 +1296,7 @@ func toolenv() []string {
                // Do not include local development, so that people working in the
                // main branch for day-to-day work on the Go toolchain itself can
                // still have full paths for stack traces for compiler crashes and the like.
-               //
-               // TODO(bcmills): This was added but commented out in CL 454836.
-               // Uncomment or delete it.
-               // env = append(env, "GOFLAGS=-trimpath")
+               env = append(env, "GOFLAGS=-trimpath")
        }
        return env
 }