]> Cypherpunks repositories - gostls13.git/commit
cmd/go: rewrite paths for overlaid files using -trimpath
authorMichael Matloob <matloob@golang.org>
Wed, 14 Oct 2020 20:21:39 +0000 (16:21 -0400)
committerMichael Matloob <matloob@golang.org>
Thu, 15 Oct 2020 21:40:46 +0000 (21:40 +0000)
commit21e441c461a79be41de20a99e6001098142946e6
treef5b825c835db45df0dff6daf97132aa7d21c0036
parent748c0d87e23eaae0ba133d2f613b82c009ac8cb4
cmd/go: rewrite paths for overlaid files using -trimpath

Pass the trimpath flag to cmd/compile to use the correct file paths
for files that are overlaid: that is, the "destination" path in the
overlay's Replace mapping rather than the "source" path.

Also fix paths to go source files provided to the gccgo compiler.

For #39958

Change-Id: I3741aeb2272bd0d5aa32cb28133b61e58264fd39
Reviewed-on: https://go-review.googlesource.com/c/go/+/257198
Trust: Michael Matloob <matloob@golang.org>
Trust: Bryan C. Mills <bcmills@google.com>
Run-TryBot: Michael Matloob <matloob@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Jay Conrod <jayconrod@google.com>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
src/cmd/go/internal/work/exec.go
src/cmd/go/internal/work/gc.go
src/cmd/go/internal/work/gccgo.go
src/cmd/go/testdata/script/build_overlay.txt
src/cmd/go/testdata/script/build_trimpath.txt